note 19769 deleted from function.gregoriantojd by jmcastagnetto
| From: | jmcastagnetto@php.net | Date: | Fri, 06 Sep 2002 22:57:48 +0000 |
| Subject: | note 19769 deleted from function.gregoriantojd by jmcastagnetto | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-36280@lists.php.net to get a copy of this message | ||
You can use the function gregoriantojd() to make the difference between two date.
$day1 = "01";
$month1 = "01";
$year1 = "2002";
$date1 = gregoriantojd($day1, $month1, $year1);
$day2 = "01";
$month2 = "01";
$year2 = "2003";
$date2 = gregoriantojd($day2, $month2, $year2);
$difference = $date2 - $date1; // This return 365
echo "There is the difference of $difference days between the two date";