note 95842 added to function.strtotime

From: Date: Mon, 25 Jan 2010 11:52:40 +0000
Subject: note 95842 added to function.strtotime
Groups: php.notes 
Request: Send a blank email to php-notes+get-165271@lists.php.net to get a copy of this message
Something worth bearing in mind for things like <?php strtotime( 'last Monday' ); ?> is that php will return the most recent monday that happened rather than the monday of 'last week'. For example <?php # Lets say today is Tuesday 19th January 2010 echo date( 'd/m/Y', strtotime( 'last Monday' ) ); # 18/01/2010 ?> when to me, 'last monday' would be 11/01/2010. ---- Server IP: 78.110.173.36 Probable Submitter: 84.12.57.91 ---- Manual Page -- http://www.php.net/manual/en/function.strtotime.php Edit -- https://master.php.net/note/edit/95842 Del: integrated -- https://master.php.net/note/delete/95842/integrated Del: useless -- https://master.php.net/note/delete/95842/useless Del: bad code -- https://master.php.net/note/delete/95842/bad+code Del: spam -- https://master.php.net/note/delete/95842/spam Del: non-english -- https://master.php.net/note/delete/95842/non-english Del: in docs -- https://master.php.net/note/delete/95842/in+docs Del: other reasons-- https://master.php.net/note/delete/95842 Reject -- https://master.php.net/note/reject/95842 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#165271) next »