|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-09-23 17:40 UTC] marcot@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Dec 19 11:00:01 2025 UTC |
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