Hi.
With 2008 having a leap-second, does PHP handle this?
In looking at http://en.wikipedia.org/wiki/Leap_second, there have
been quite a few leap seconds - 34 since Jan 1st 1972.
So, if PHP isn't making any changes does this mean PHP time is 34
seconds behind UTC?
Regards,
Richard
--
Richard Quadling
Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498&r=213474731
"Standing on the shoulders of some very clever giants!"
Richard Quadling wrote:
Hi.
With 2008 having a leap-second, does PHP handle this?
In looking at http://en.wikipedia.org/wiki/Leap_second, there have
been quite a few leap seconds - 34 since Jan 1st 1972.So, if PHP isn't making any changes does this mean PHP time is 34
seconds behind UTC?Regards,
PHP does what most operating systems and ignores the leap seconds.
Scott
Hi Richard,
In looking at http://en.wikipedia.org/wiki/Leap_second, there have
been quite a few leap seconds - 34 since Jan 1st 1972.
I make it 23, according to the info on that page...
So, if PHP isn't making any changes does this mean PHP time is 34
seconds behind UTC?
No.
This would be a red herring anyway Richard, the Olson tz database used by
PHP is used by several other projects too - including the GNU C library.
http://en.wikipedia.org/wiki/Zoneinfo
- Steph
2008/12/18 Steph Fox steph@php.net:
Hi Richard,
In looking at http://en.wikipedia.org/wiki/Leap_second, there have
been quite a few leap seconds - 34 since Jan 1st 1972.I make it 23, according to the info on that page...
So, if PHP isn't making any changes does this mean PHP time is 34
seconds behind UTC?No.
This would be a red herring anyway Richard, the Olson tz database used by
PHP is used by several other projects too - including the GNU C library.http://en.wikipedia.org/wiki/Zoneinfo
- Steph
--
You are missing the 10 that were initially done between TAI and UTC
and the 23 subsequent ones with one more at the end of the year = 34.
So 33 seconds then.
--
Richard Quadling
Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498&r=213474731
"Standing on the shoulders of some very clever giants!"
With 2008 having a leap-second, does PHP handle this?
In looking at http://en.wikipedia.org/wiki/Leap_second, there have
been quite a few leap seconds - 34 since Jan 1st 1972.So, if PHP isn't making any changes does this mean PHP time is 34
seconds behind UTC?
No: http://derickrethans.nl/php_lags_23_seconds.php
regards,
Derick
Hm, Wikipedia's apparently less than open there -
[12:36] <otherbird> so how come PHP's different?
[12:36] <Derick> olson has information on it, but it's never used
- Steph
Richard Quadling wrote:
Hi.
With 2008 having a leap-second, does PHP handle this?
In looking at http://en.wikipedia.org/wiki/Leap_second, there have
been quite a few leap seconds - 34 since Jan 1st 1972.So, if PHP isn't making any changes does this mean PHP time is 34
seconds behind UTC?
Unix time conventionally does not include leap seconds. This allows
ordinary applications to convert seconds-since-epoch to calendar dates
without any knowledge of leap seconds. Ntpd is tasked with changing the
system clock to account for this, ultimately in response to a leap
second change propagated from the stratum 1 time servers.
http://www.eecis.udel.edu/~mills/leap.html
-- Tim Starling