Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 706733
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T04:11:56+00:00 2026-05-14T04:11:56+00:00

My web application consists of library type system where books have due dates. I

  • 0

My web application consists of library type system where books have due dates.

I have the current date displayed on my page, simply by using this:

date_default_timezone_set('Europe/London');

$date = date;
print $date("d/m/Y");

I have set ‘date’ as a variable because I’m not sure if it makes a difference when I use it in the IF statement you’re about see, on my library books page.

On this page, I am simply outputting the due dates of the books, many have dates which have not yet reached todays date, and others which have dates greater than todays date.
Basically, all I want is the due date to appear bold (or strong), if it has passed todays date (the system displayed date). This is what I have and thought would work:

<?
if ($duedate < $date) {
  echo '<td><strong>';
} else {
  echo '<td>';
} ?>

<?php echo $date('d/m/Y', $timestamp);?></strong></td>

I have declared $timestamp as a var which converts the date of default MySQL format to a UK version. Can anyone help me out? I thought this would’ve been very straight forward!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T04:11:57+00:00Added an answer on May 14, 2026 at 4:11 am

    try:

    if (strtotime($duedate) < time()) {
        // oooh, your book is late!
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In my web-application i have a div which loads another page: $('#main').load('pages/main.php'); main.php consists
I have a web application that consists of Website and REST API. Should I
I have a web application that consists of two websites - one running on
I have added an MVC3 web application to an existing website that consists of
I have ASP.NET MVC web application. I need to deploy it which consists of:
I have a web application that consists of a web service with two operations:
I created java enterprise application and it consists of ejb module and web application.
I'm building a web based application to determine a value, which consists the calculation
My web application is written using jsp/javascripts. Backend Java. Have managed to implement the
I have an ASP.NET c# web application published to a server of ours. It

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.