|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #33919 Wrong timestamp return
Submitted: 2005-07-29 15:21 UTC Modified: 2005-08-06 01:00 UTC
Avg. Score:5.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: gustavog at dextra dot com dot br Assigned:
Status: No Feedback Package: Date/time related
PHP Version: 5.0.4 OS: debian-sarge
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2005-07-29 15:21 UTC] gustavog at dextra dot com dot br
When I user the function strtotime on february, I get a wrong timestamp.

Reproduce code:
$timestamp = strtotime("1 february 2005");
$timestamp = strtotime("2 Monday", $timestamp);
//No problem display "14-02-2005 -- Monday"
echo date("d-m-Y -- l ", $timestamp);
echo "<br />";
$timestamp = strtotime("1 february 2005");	
$timestamp = strtotime("3 Monday", $timestamp);	
//Display 20-02-2005 -- Sunday instead of 21-02-2005 -- Monday
echo date("d-m-Y -- l ", $timestamp);

Expected result:
The second echo command should display the third Monday of february, but it displays Sunday.


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2005-07-29 15:26 UTC]
Please try using this CVS snapshot:
For Windows:

 [2005-08-06 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
PHP Copyright © 2001-2018 The PHP Group
All rights reserved.
Last updated: Sun Dec 16 23:01:25 2018 UTC