#34618 [Opn->Csd]: unexpected strtotime output
| From: | marcot@php.net | Date: | Fri, 23 Sep 2005 15:40:51 +0000 |
| Subject: | #34618 [Opn->Csd]: unexpected strtotime output | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-85509@lists.php.net to get a copy of this message | ||
ID: 34618
Updated by: marcot@php.net
Reported By: technophreak at gammae dot com
-Status: Open
+Status: Closed
Bug Type: Date/time related
Operating System: fedora code 2
PHP Version: 5.0.5
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.
Works for me on current CVS in the 5_1 branch.
Previous Comments:
------------------------------------------------------------------------
[2005-09-23 17:30:01] technophreak at gammae dot com
Description:
------------
Some dates does not output properly with strtotime()
Works fine on PHP 4.3
Reproduce code:
---------------
$date = "2005-10-30 01:00:00";
$format = "Y-m-d H:i:s";
print date($format,strtotime("1 hour",strtotime($date)))."\n";
print date($format,strtotime("2 hour",strtotime($date)))."\n";
Expected result:
----------------
2005-10-30 02:00:00
2005-10-30 03:00:00
Actual result:
--------------
2005-10-30 01:00:00
2005-10-30 02:00:00
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=34618&edit=1