On Wednesday 11 June 2003 02:52, LeTortorec, Jean-Louis wrote:

> Do you know how to calculate the number of days between 2 dates?
>
> So far, I used that function:
>
>       $a=mktime("","","",$month1, $day1, $year1);
>       $b=mktime("","","",$month2, $day2, $year2);
>       $c=($a-$b)/(60*60*24);
>
> The problem is one date is prior to 01/01/1970, the mktime function does
> not work.

Have a look at the Calendar functions.

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
------------------------------------------
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
------------------------------------------
/*
No man would listen to you talk if he didn't know it was his turn next.
                -- E.W. Howe
*/


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

Reply via email to