php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #18770 Wrong ISO-8601 week number
Submitted: 2002-08-07 04:21 UTC Modified: 2002-08-07 04:41 UTC
From: henrie dot cuijpers at zonnet dot nl Assigned:
Status: Closed Package: Date/time related
PHP Version: 4.2.1 OS: Win2k
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: henrie dot cuijpers at zonnet dot nl
New email:
PHP Version: OS:

 

 [2002-08-07 04:21 UTC] henrie dot cuijpers at zonnet dot nl
2 examples: Try:

date("W",mktime (0,0,0,12,31,2001))  gives week 53. 
This should be week 1 of year 2002.

date("W",mktime (0,0,0,1,2,2000))    gives week 0.
This should be week 52 of year 1999.

So:
1) the weeknumber is not correct
2) you should also be able to get the iso Year because this can be different from the year.

I hope this helps in getting a better world....



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-08-07 04:41 UTC] eru@php.net
This bug has been fixed in CVS. You can grab a snapshot of the
CVS version at http://snaps.php.net/. In case this was a documentation 
problem, the fix will show up soon at http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites.
Thank you for the report, and for helping us make PHP better.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 26 17:01:30 2024 UTC