#48424 [Ver->Bgs]: strtotime changes year to current year with date formatted "17 July, 2004"
| From: | derick@php.net | Date: | Fri, 29 May 2009 12:48:58 +0000 |
| Subject: | #48424 [Ver->Bgs]: strtotime changes year to current year with date formatted "17 July, 2004" | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-137873@lists.php.net to get a copy of this message | ||
ID: 48424
Updated by: derick@php.net
Reported By: php at qrs dot oib dot com
-Status: Verified
+Status: Bogus
Bug Type: Date/time related
Operating System: *
PHP Version: 5.*, 6CVS (2009-05-29)
New Comment:
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to
report
a bug at http://bugs.php.net/how-to-report.php
THis is how the parser works, check with var_dump(date_parse("17 July,
2004"));
Previous Comments:
------------------------------------------------------------------------
[2009-05-29 04:36:35] php at qrs dot oib dot com
Description:
------------
strtotime changes the year to the current year with a date formatted
like "17 July, 2004".
Reproduce code:
---------------
print strftime("%d %B, %Y", strtotime("July 17, 2004"));
print strftime("%d %B, %Y", strtotime("17 July, 2004")); // <---
print strftime("%d %B, %Y", strtotime("17 July 2004"));
Expected result:
----------------
17 July, 2004
17 July, 2004
17 July, 2004
Actual result:
--------------
17 July, 2004
17 July, 2009
17 July, 2004
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=48424&edit=1