Req #63776 [NEW]: Fails With 'at'
| From: | matthewcomp at hotmail dot com | Date: | Fri, 14 Dec 2012 22:53:59 +0000 |
| Subject: | Req #63776 [NEW]: Fails With 'at' | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-175373@lists.php.net to get a copy of this message | ||
From: matthewcomp at hotmail dot com
Operating system: Linux gator1111.hostgator.com 3.
PHP version: 5.4.9
Package: Date/time related
Bug Type: Feature/Change Request
Bug description:Fails With 'at'
Description:
------------
---
From manual page: http://www.php.net/function.strtotime
---
Does not work to read a date in the following format:
Nov 19, 2012 at 7:03 PM
Test script:
---------------
<?php
$date = "Nov 19, 2012 at 7:03 PM";
if (($timestamp = strtotime($date)) === false) {
echo "The string ($date) is bogus";
} else {
echo "$date => " . date('l dS \o\f F Y h:i:s A', $timestamp);
}
?>
Expected result:
----------------
Correctly parse the date, ignoring at, which can commonly appear in dates.
Actual result:
--------------
Completely unable to parse the date.
--
Edit bug report at https://bugs.php.net/bug.php?id=63776&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=63776&r=trysnapshot54
Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=63776&r=trysnapshot53
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=63776&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=63776&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=63776&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=63776&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=63776&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=63776&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=63776&r=support
Expected behavior: https://bugs.php.net/fix.php?id=63776&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=63776&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=63776&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=63776&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=63776&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=63776&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=63776&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=63776&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=63776&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=63776&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=63776&r=mysqlcfg