Something like this..

$start = "2002-10-9";
$end = "2002-11-16";
$arStart = explode("-", $start);
$arEnd = explode("-", $end);
$startTime = date("U", mktime(0,0,0,$arStart[1], $arStart[2], $arStart[0]));
$endTime = date("U", mktime(0,0,0,$arEnd[1], $arEnd[2], $arEnd[0]));
$dif = $endTime - $startTime; // in seconds

That will do it but you could simplfy it with some more advanced techniques.

-Jared



-----Original Message-----
From: Jeroen Timmers [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 28, 2002 2:17 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Dates


i have two dates

for example

2002-10-9 and 2002-11-16

Is there a function to see how many day's between thore date's is?

Jeroen


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



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

Reply via email to