php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #62391 format('W')
Submitted: 2012-06-22 04:11 UTC Modified: 2012-06-22 08:23 UTC
From: master dot zion at gmail dot com Assigned:
Status: Not a bug Package: Unknown/Other Function
PHP Version: 5.3Git-2012-06-22 (Git) OS: windows
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
23 + 19 = ?
Subscribe to this entry?

 
 [2012-06-22 04:11 UTC] master dot zion at gmail dot com
Description:
------------
$td1 = new DateTime('01/01/2012');
echo $td1->format("W"); // 52 ???


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-06-22 08:23 UTC] cataphract@php.net
-Status: Open +Status: Not a bug
 [2012-06-22 08:23 UTC] cataphract@php.net
Not a bug. In general, Jan 1 is not in week 1. Week 1 is the first week that contains at least 4 days from that year, and for this purpose weeks are deemed to start on Mondays.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 23 16:01:30 2024 UTC