> How can I compare two dates with PHP, to see if one date occurred before
> the other?

probably not the best way but:

if the date is formated like this 20030929 (today) 20030928 (yesterday)
I think it is quite easy:
if ( (int)$today > (int)$yesterday )
or perhaps like this:
if ( strcmp($today, $yesterday) )

if you have to change the format, you can use :
http://www.php.net/manual/en/function.preg-replace.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to