Marcus Bointon wrote:
How is this not a bug?
?php
print date('Y-m-d H:i:s', strtotime('now UTC')).\n;
print date('Y-m-d H:i:s', strtotime('now PST')).\n;
?
outputs:
2005-01-18 09:58:09 (correct)
2005-01-18 17:58:09 (incorrect)
PST = UTC - 8, therefore if you ask for strtotime in PST it will give
On 18 Jan 2005, at 10:53, Tom wrote:
PST = UTC - 8, therefore if you ask for strtotime in PST it will give
you now + 8. This is standard in most languages, you are just reading
the functionality back to front.
ie when you say strtotome('now PST'), what you are asking for is the
current local
Marcus Bointon wrote:
On 18 Jan 2005, at 10:53, Tom wrote:
PST = UTC - 8, therefore if you ask for strtotime in PST it will give
you now + 8. This is standard in most languages, you are just
reading the functionality back to front.
ie when you say strtotome('now PST'), what you are asking for
Marcus Bointon wrote:
On 18 Jan 2005, at 10:53, Tom wrote:
PST = UTC - 8, therefore if you ask for strtotime in PST it will give
you now + 8. This is standard in most languages, you are just reading
the functionality back to front.
ie when you say strtotome('now PST'), what you are asking for
Tom wrote:
Marcus Bointon wrote:
On 18 Jan 2005, at 10:53, Tom wrote:
PST = UTC - 8, therefore if you ask for strtotime in PST it will give
you now + 8. This is standard in most languages, you are just
reading the functionality back to front.
ie when you say strtotome('now PST'), what you are
Marcus Bointon wrote:
Much of the point of using zone names rather than fixed numeric
offsets is that it allows for correct daylight savings calculations
(assuming that locale data is correct on the server).
Let me rephrase the question - how can I get the current time in a
named time zone
6 matches
Mail list logo