note 26710 added to function.date
| From: | richard at rack1 dot php dot net | Date: | Sun, 10 Nov 2002 00:42:44 +0000 |
| Subject: | note 26710 added to function.date | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-39246@lists.php.net to get a copy of this message | ||
A more simpliest way to know the last date in a month. Say that $currentmonth hold the month
you're looking for, so
$timestamp = mktime(0,0,0,$currentmonth);
echo date("t",$timestamp);
should return the last date in the said month.
Ciao
--
http://www.php.net/manual/en/function.date.php
http://master.php.net/manage/user-notes.php?action=edit+26710
http://master.php.net/manage/user-notes.php?action=delete+26710
http://master.php.net/manage/user-notes.php?action=reject+26710