note 113788 added to function.strtotime
| From: | ChristianL. | Date: | Sun, 01 Dec 2013 20:45:08 +0000 |
| Subject: | note 113788 added to function.strtotime | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-197687@lists.php.net to get a copy of this message | ||
To get the start of the current week this code works fine when the week starts on Sundays.
<?php strtotime('this Monday'); ?>
To get the timestamp of the start of a week starting on Mondays (as defined by ISO 8601) this shoud
do the trick.
<?php strtotime('next Monday -1 week'); ?>
----
Server IP: 192.41.45.150
Probable Submitter: 62.245.151.72
----
Manual Page -- http://php.net/manual/en/function.strtotime.php
Edit -- https://master.php.net/note/edit/113788
Del: integrated -- https://master.php.net/note/delete/113788/integrated
Del: useless -- https://master.php.net/note/delete/113788/useless
Del: bad code -- https://master.php.net/note/delete/113788/bad+code
Del: spam -- https://master.php.net/note/delete/113788/spam
Del: non-english -- https://master.php.net/note/delete/113788/non-english
Del: in docs -- https://master.php.net/note/delete/113788/in+docs
Del: other reasons-- https://master.php.net/note/delete/113788
Reject -- https://master.php.net/note/reject/113788
Search -- https://master.php.net/manage/user-notes.php