ID:               42155
 Updated by:       [EMAIL PROTECTED]
 Reported By:      ahlers_wim at hotmail dot com
-Status:           Open
+Status:           Bogus
 Bug Type:         Date/time related
 Operating System: All
 PHP Version:      5.2.3
 New Comment:

Years divisible by 400 *are* leap years,
Years divisible by 100 are not leap years
Years divisible by 4 *are* leap years

php -r "var_dump(checkdate(2, 29, 2000));"
bool(true)

php -r "var_dump(checkdate(2, 29, 2100));"
bool(false)

php -r "var_dump(checkdate(2, 29, 2200));"
bool(false)

php -r "var_dump(checkdate(2, 29, 2300));"
bool(false)

php -r "var_dump(checkdate(2, 29, 2400));"
bool(true)


Previous Comments:
------------------------------------------------------------------------

[2007-07-31 09:40:42] ahlers_wim at hotmail dot com

Description:
------------
Dates divisible by 400 should not be a leap year. (for milleniums to
come.)
checkdate() should be modified to incorporate this date related cycle.

Reproduce code:
---------------
checkdate(2, 29, 2000);

Expected result:
----------------
FALSE

Actual result:
--------------
TRUE


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=42155&edit=1

Reply via email to