Forum Moderators: coopster
Is there a date function to do this? I have looked but cannot find a bit of code to adapt.
Regards
I'll take it that you can build that date. Lets say that $date1 is the first date and $date2 is the second date.
$result=strcmp($date1,$date2);
strcmp is a string comparison function but will work fine in this case.
if $result is 0 then $date1 and $date2 are the same.
if $result is < 0 $date1 is less than $date2
if $result is > 0 $date1 is greater than $date2
This should give you the test you need.
daisho.