From 7be49951cf75379ba5d4ee4782e1aefeb452dc35 Mon Sep 17 00:00:00 2001 From: Torben Wilson Date: Tue, 15 Sep 2009 06:28:00 +0000 Subject: [PATCH] Documented the old incorrect behaviour that requesting a given occurrence of a weekday in a month when that weekend occurred on the first day of the month would add one week to the returned timestamp. Addresses bug #46932 Not sure this should be a warning. Seems more appropriate in the changelog section. I'm just putting it here now to be consistent with the existing function reference. git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@288346 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/datetime/functions/strtotime.xml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/reference/datetime/functions/strtotime.xml b/reference/datetime/functions/strtotime.xml index 4276287c40..e41d8e46e3 100644 --- a/reference/datetime/functions/strtotime.xml +++ b/reference/datetime/functions/strtotime.xml @@ -148,10 +148,17 @@ if (($timestamp = strtotime($str)) === false) { &reftitle.notes; + + + In PHP 5 prior to 5.2.7, requesting a given occurrence of a given + weekday in a month where that weekday was the first day of the + month would incorrectly add one week to the returned timestamp. + + In PHP 5 up to 5.0.2, "now" and other relative times - are wrongly computed from today's midnight. It differs from other + are wrongly computed from today's midnight. This differs from other versions where it is correctly computed from current time.