#39026 [Opn->Asn]: strtotime("060901") does not produce a correct date stamp for 2006-09-01
| From: | tony2001@php.net | Date: | Tue, 03 Oct 2006 17:56:55 +0000 |
| Subject: | #39026 [Opn->Asn]: strtotime("060901") does not produce a correct date stamp for 2006-09-01 | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-103047@lists.php.net to get a copy of this message | ||
ID: 39026
Updated by: tony2001@php.net
Reported By: dbrong at gmail dot com
-Status: Open
+Status: Assigned
Bug Type: Date/time related
Operating System: Windows 2000
PHP Version: 5CVS-2006-10-03 (snap)
-Assigned To:
+Assigned To: derick
Previous Comments:
------------------------------------------------------------------------
[2006-10-03 14:57:38] dbrong at gmail dot com
Description:
------------
I was using date("Y-m-d", strtotime("060901")) to produce a date
formatted as "2006-09-01" and this does not work anymore in the latest
PHP 5 release. It produces the actual date of the system's current
time (2006-10-03 in this case).
If I modify it as strtotime("20060901") it works fine.
Reproduce code:
---------------
date("Y-m-d", strtotime("060901")) will output the current system date
(2006-10-03 in this case).
Expected result:
----------------
2006-10-03 (or the current date you run the script)
Actual result:
--------------
should be 2006-09-01
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=39026&edit=1