note 105506 deleted from function.date by peehaa

From: Date: Fri, 06 Jan 2017 15:53:41 +0000
Subject: note 105506 deleted from function.date by peehaa
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-208700@lists.php.net to get a copy of this message
Note Submitter: blinov vyacheslav AT gmail.com ---- It was oblivious and discouraging that it dont mentioned in docs. If you will use W to get week number be aware: first days of year can be in a week of previous year, and week number always has leading zero <?php echo date("YW", strtotime("2011-01-07")); // gives 201101 echo date("YW", strtotime("2011-01-01")); // gives 201152 echo date("YW", strtotime("2011-12-31")); // gives 201152 too ?> so you can`t rely on number of week given from this function inside your program if you want to use it for some logic

« previous php.notes (#208700) next »