#32588 [Asn->Csd]: strtotime() error for 'last xxx' DST problem
| From: | derick@php.net | Date: | Thu, 16 Jun 2005 19:12:29 +0000 |
| Subject: | #32588 [Asn->Csd]: strtotime() error for 'last xxx' DST problem | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-80480@lists.php.net to get a copy of this message | ||
ID: 32588
Updated by: derick@php.net
Reported By: alan at ridersite dot org
-Status: Assigned
+Status: Closed
Bug Type: Date/time related
Operating System: Linux
PHP Version: 5.0.3, 4.3.10
Assigned To: derick
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.
Fixed for PHP 5.1.
Previous Comments:
------------------------------------------------------------------------
[2005-04-09 00:08:27] cdarklock at injuryfree dot com
Having same bug on 5.0.3; looks to be a simple fix in parsedate.y for
someone that knows his way around it, but I'm not that someone.
------------------------------------------------------------------------
[2005-04-05 14:32:55] derick@php.net
Might be a duplicate, but will check it out.
------------------------------------------------------------------------
[2005-04-05 14:21:21] alan at ridersite dot org
Description:
------------
strtotime() in error when DST is bridged.
Code illustrates bug
Reproduce code:
---------------
echo date('D Y/m/d/H:i:s', time()). "<br>";
echo date('D Y/m/d/H:i:s', strtotime('last saturday')). "<br>";
echo date('D Y/m/d/H:i:s', strtotime("last sunday")). "<br>";
echo date('D Y/m/d/H:i:s', strtotime('last monday')). "<br>";
Expected result:
----------------
Tue 2005/04/05/08:15:48
Sat 2005/04/02/00:00:00
Sun 2005/04/03/00:00:00
Mon 2005/04/04/00:00:00
Actual result:
--------------
Tue 2005/04/05/08:15:48
Fri 2005/04/01/23:00:00
Sat 2005/04/02/23:00:00
Mon 2005/04/04/00:00:00
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=32588&edit=1