DATE_ISO8601 and the "c" date() character

php.internals

Hannes Magnusson

20 years ago
Hi all I just noticed that the DATE_ISO8601 constant and the "c" date() character don't give the same results. The difference is that the "c" format prints colon in the timezone offset, but the constant does not - both are however ISO8601 compliant. Is this intentional? If not, I'd want to change the constant rather then "c", since the "c" format has been there since 5.0 but the constant since 5.1.1. Patch attached (and patch for phpdoc). However! I think ISO8601 formats without the colon are more used.., not sure if this should be changed at all.... - Hannes

Hannes Magnusson

20 years ago
Hmh. No. The patches weren't attached ;) On 1/31/06, Hannes Magnusson <hannes.magnusson@gmail.com> wrote:

Derick Rethans

20 years ago
On Tue, 31 Jan 2006, Hannes Magnusson wrote:
> I just noticed that the DATE_ISO8601 constant and the "c" date() > character don't give the same results. > The difference is that the "c" format prints colon in the timezone > offset, but the constant does not - both are however ISO8601 > compliant.
<snip>
> However! I think ISO8601 formats without the colon are more used.., > not sure if this should be changed at all....
Indeed, I don't think we should change this. As long as it is properly documented of course. regards, Derick
-- Derick Rethans http://derickrethans.nl | http://ez.no | http://xdebug.org