ID: 35558 Updated by: [EMAIL PROTECTED] Reported By: marcel at daxy dot net -Status: Open +Status: Closed Bug Type: Feature/Change Request Operating System: Linux 2.6.9 PHP Version: 5.1.1 New Comment:
This bug has been fixed in CVS. Snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. Thank you for the report, and for helping us make PHP better. Previous Comments: ------------------------------------------------------------------------ [2005-12-05 17:17:42] marcel at daxy dot net Description: ------------ localtime returns years after 1900, so for 2005 it's 105. When using this number back into mktime it returns FALSE with 5.1.1. When using 5.0.x it returns the correct value. Try running the code at "Reproduce code" with both 5.1 and 5.0. This is expected behavior, but due to backwards compatibility it would be nice to have this interpreted differently. Reproduce code: --------------- <? $ltime = localtime(time(), true); print mktime (0,0,0,0,0,$ltime['tm_year']); ?> Expected result: ---------------- Because of the behavior of localtime it would be nice to have the correct value returned with mktime ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=35558&edit=1