From: [email protected]
Operating system: Any
PHP version: 5.2.8
PHP Bug Type: Date/time related
Bug description: DATE_ISO8601 constant and date('c') mismatch
Description:
------------
Following the documentation, DATE_ISO8601 contains this syntax:
2005-08-15T15:52:01+0000
Also, date('c') documents that: ISO 8601 date (added in PHP 5)
2004-02-12T15:19:21+00:00
We should keep consistency when supporting this spec.
I propose the change then to DATE_ISO8601 constant, defined in
ext/date/php_date.c, line 714:
- #define DATE_FORMAT_ISO8601 "Y-m-d\\TH:i:sO"
+ #define DATE_FORMAT_ISO8601 "Y-m-d\\TH:i:sP"
Reproduce code:
---------------
echo DATE_ISO8601 === date('c') ? 'true' : 'false';
Expected result:
----------------
true
Actual result:
--------------
false
--
Edit bug report at http://bugs.php.net/?id=47184&edit=1
--
Try a CVS snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=47184&r=trysnapshot52
Try a CVS snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=47184&r=trysnapshot53
Try a CVS snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=47184&r=trysnapshot60
Fixed in CVS:
http://bugs.php.net/fix.php?id=47184&r=fixedcvs
Fixed in CVS and need be documented:
http://bugs.php.net/fix.php?id=47184&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=47184&r=alreadyfixed
Need backtrace:
http://bugs.php.net/fix.php?id=47184&r=needtrace
Need Reproduce Script:
http://bugs.php.net/fix.php?id=47184&r=needscript
Try newer version:
http://bugs.php.net/fix.php?id=47184&r=oldversion
Not developer issue:
http://bugs.php.net/fix.php?id=47184&r=support
Expected behavior:
http://bugs.php.net/fix.php?id=47184&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=47184&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=47184&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=47184&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=47184&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=47184&r=dst
IIS Stability:
http://bugs.php.net/fix.php?id=47184&r=isapi
Install GNU Sed:
http://bugs.php.net/fix.php?id=47184&r=gnused
Floating point limitations:
http://bugs.php.net/fix.php?id=47184&r=float
No Zend Extensions:
http://bugs.php.net/fix.php?id=47184&r=nozend
MySQL Configuration Error:
http://bugs.php.net/fix.php?id=47184&r=mysqlcfg