note 48014 added to function.strtotime

From: Date: Thu, 09 Dec 2004 04:12:54 +0000
Subject: note 48014 added to function.strtotime
Groups: php.notes 
Request: Send a blank email to php-notes+get-81566@lists.php.net to get a copy of this message
Be warned that strtotime() tries to "guess what you meant" and will successfully parse dates that would otherwise be considered invalid: <?php $ts = strtotime('1999-11-40'); echo date('Y-m-d', $ts); // outputs: 1999-12-10 ?> It is my understanding (I have not verified) that the lexer for strtotime() has been rewritten for PHP5, so these semantics may only apply for PHP4 and below. ---- Manual Page -- http://www.php.net/manual/en/function.strtotime.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+48014 Delete -- http://master.php.net/manage/user-notes.php?action=delete+48014&report=yes Reason: bad code -- http://master.php.net/manage/user-notes.php?action=delete+48014&report=yes&reason=bad+code Reason: spam -- http://master.php.net/manage/user-notes.php?action=delete+48014&report=yes&reason=spam Reason: useless example -- http://master.php.net/manage/user-notes.php?action=delete+48014&report=yes&reason=useless+example Reason: contains commercial links -- http://master.php.net/manage/user-notes.php?action=delete+48014&report=yes&reason=contains+commercial+links Reason: useless note -- http://master.php.net/manage/user-notes.php?action=delete+48014&report=yes&reason=useless+note Reject -- http://master.php.net/manage/user-notes.php?action=reject+48014&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#81566) next »