Re: time zone ignored (both via ini or in code)
| From: | Nathan Nobbe | Date: | Tue, 02 Nov 2010 16:37:38 +0000 |
| Subject: | Re: time zone ignored (both via ini or in code) | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-309240@lists.php.net to get a copy of this message | ||
On Tue, Nov 2, 2010 at 10:11 AM, Dan Yost <yodano@gmail.com> wrote:
> On Tue, Nov 2, 2010 at 11:02 AM, Nathan Nobbe <quickshiftin@gmail.com>
> wrote:
> >> >>
> >> >> So now I suppose the thread becomes: how do I get a valid US/Central
> >> >> (America/Chicago) timezone in PHP5?
> >> >
> >> > give the timezonedb extension a shot
> >> > http://pecl.php.net/package/timezonedb
> >>
> >>
> >> Tried it, no change. It is still impossible to get simple CENTRAL
> >> timezone output. This is maddening.
> >
> > That's really weird since I'm sure php has its own timezone db, and it
> > sounds like that's where PHP is getting it if you saw the correct output
> > after switching date.timezone to America/Denver. What about trying
> > date_default_timezone_set() ?
>
>
> I had tried that originally too. It does set the timezone "correctly,"
> but then again so does the ini set. So the timezone does get set to
> America/Chicago with a date_default_timezone_set(), and then PHP
> shanks from there, showing UTC. It seems certain that the timezone
> *does* get set to America/Chicago (via multiple methods), and that
> America/Chicago *itself* is corrupt in PHP--and that's even with
> timezonedb installed. Now everybody knows Chicago is full of
> corruption, but at least the clocks aren't, right?
>
> Surely there are bizillions of others out there running this
> combination of software in the Central time zone! Yet it's as if
> nobody else has corrupt timezone DB records (be they internal or via
> timezonedb) except me. And I can't help but notice how CentOS (tzdata
> package) is also corrupt, every single time it gets updated, on the
> Central zone but no others. Obviously these should be entirely
> separate issues, but "somebody" out there has it out for the Central
> time zone. Probably a Yankees fan.
dude at this point i dont want to sound too much like a troll, but php 5.1
is some really old software. frankly this is why i chose not to run on
centos during my evaluation of it. i understand the concept behind running
proven stable software, but i think centos is taking that notion to the
extreme. i would probly try building a more recent version of php from
source and see if that helps.
-nathan