note 59408 added to function.date
| From: | krizanovskij at siol dot net | Date: | Tue, 06 Dec 2005 09:25:03 +0000 |
| Subject: | note 59408 added to function.date | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-99625@lists.php.net to get a copy of this message | ||
Countdown:
<?php
$day = 8; // Day
$month = 8; // Month
$year = 2008; // Year
if ($month == 1) $month_name= "January";
if ($month == 2) $month_name= "February";
if ($month == 3) $month_name= "March";
if ($month == 4) $month_name= "April";
if ($month == 5) $month_name= "May";
if ($month == 6) $month_name= "June";
if ($month == 7) $month_name= "July";
if ($month == 8) $month_name= "August";
if ($month == 9) $month_name= "September";
if ($month == 10) $month_name= "October";
if ($month == 11) $month_name= "November";
if ($month == 12) $month_name= "December";
print ("There are " . (int)((mktime (0,0,0,$month,$day,$year) - time(void))/86400) .
" days until $month_name $day, $year");
?>
----
Manual Page -- http://www.php.net/manual/en/function.date.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+59408
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+59408&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+59408&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+59408&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+59408&report=yes&reason=useless
Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+59408&report=yes&reason=non-english
Delete: already in docs -- http://master.php.net/manage/user-notes.php?action=delete+59408&report=yes&reason=already+in+docs
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+59408&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+59408&report=yes
Search -- http://master.php.net/manage/user-notes.php