|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-07-11 21:04 UTC] derick@php.net
[2007-07-11 21:38 UTC] bealdrid at gmail dot com
[2007-07-11 21:41 UTC] derick@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Dec 03 01:00:01 2025 UTC |
Description: ------------ when calling the strtotime() function and when passing a time before the day such as "1pm yesterday" the wrong timestamp is returned, often midnite of that particular day. Reproduce code: --------------- echo date('Y-m-d H:i:s',strtotime('1pm yesterday')); Expected result: ---------------- The expected result would be 2007-07-08 13:00:00 and this works in php 4.3.9 If I put the time after the day, such as "yesterday 1pm", it behaves as expected. Actual result: -------------- 2007-07-08 00:00:00