Re: Getting separate outputs with Date Functions

From: Date: Tue, 05 Mar 2013 20:59:43 +0000
Subject: Re: Getting separate outputs with Date Functions
References: 1 2 3 4  Groups: php.internals 
Request: Send a blank email to internals+get-66479@lists.php.net to get a copy of this message
On Wed, Feb 20, 2013 at 1:54 PM, David Soria Parra <dsp@php.net> wrote:
I ran into this myself and I personally consider date() assuming your configured TZ A bug.
The description for date() says "local time/date" => considering TZ is not a bug.
Timestamps are defined as UTC and the behaviour of DateTime is correct there, that it always assume UTC. date() should do the same.
I rather think DateTime::__construct/date_create were wrongly designed for ignoring the second parameter. Timestamps specify a uniform reference of time, but just because you use them doesn't imply you're sitting in any particular TZ. Steve Clay -- http://www.mrclay.org/

« previous php.internals (#66479) next »