note 93465 added to function.date
| From: | lb at bostontech dot net | Date: | Fri, 11 Sep 2009 08:06:51 +0000 |
| Subject: | note 93465 added to function.date | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-160443@lists.php.net to get a copy of this message | ||
@ Just.Kevin
Thanks for your note... it inspired me to make a compact leap year checking function:
function isLeapYear($year = 2100)
{ return ((($year%4==0) && ($year%100)) || $year%400==0) ? (true):(false); }
... again I'm uncertain if this is going to perform better than the date() function built in,
but at least it is lean.
----
Server IP: 117.55.229.1
Probable Submitter: 203.59.102.142
----
Manual Page -- http://www.php.net/manual/en/function.date.php
Edit -- https://master.php.net/note/edit/93465
Del: integrated -- https://master.php.net/note/delete/93465/integrated
Del: useless -- https://master.php.net/note/delete/93465/useless
Del: bad code -- https://master.php.net/note/delete/93465/bad+code
Del: spam -- https://master.php.net/note/delete/93465/spam
Del: non-english -- https://master.php.net/note/delete/93465/non-english
Del: in docs -- https://master.php.net/note/delete/93465/in+docs
Del: other reasons-- https://master.php.net/note/delete/93465
Reject -- https://master.php.net/note/reject/93465
Search -- https://master.php.net/manage/user-notes.php