ShaolinF Posted November 27, 2009 Share Posted November 27, 2009 Hi Guys I have two dates I want to compare. Below is my current implementation. The problem with it is it always returns false: if(date("d/m/y", $course->finish_date) > date("d/m/y", $today[0])) // do somemthing else // do something Quote Link to comment https://forums.phpfreaks.com/topic/183162-comparing-two-dates/ Share on other sites More sharing options...
Alex Posted November 27, 2009 Share Posted November 27, 2009 If $course->finish_date and $today[0] are both unix timestamps just compare those. Quote Link to comment https://forums.phpfreaks.com/topic/183162-comparing-two-dates/#findComment-966623 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.