Re: [PHP] Using DateTimeZone

2008-12-04 Thread Jochem Maas
Lester Caine schreef: > Lester Caine wrote: >>> >> >>> setlocale(LC_TIME, "nl_NL.ISO8859-1"); >>> $d = new DateTime(); >>> echo strftime("%A, %d %B %Y", strtotime($d->format(DATE_ATOM))), "\n"; >>> >>> ?> > > Does not work! it does, only there is nothing setting the timezone in that example. > H

Re: [PHP] Using DateTimeZone

2008-12-04 Thread Lester Caine
Lester Caine wrote: format(DATE_ATOM))), "\n"; ?> Does not work! Have to do date_default_timezone_set( $user_timezone ) ); if ( is_numeric( $user_time )) { $dateTimeUser = new DateTime( '@'.$user_time ); } else { $dateTimeUser = new DateTime( $user_time ); } $disptime = strto

Re: [PHP] Using DateTimeZone

2008-12-04 Thread Lester Caine
Jochem Maas wrote: Lester Caine schreef: Lester Caine wrote: Lester Caine wrote: I'm looking to tidy up things a bit by clearing out a lot of old code and switching to using the internal DateTime functions. Information is stored in the databases UTC normalized, and we get around the problem o

Re: [PHP] Using DateTimeZone

2008-12-04 Thread Jochem Maas
Lester Caine schreef: > Lester Caine wrote: >> Lester Caine wrote: >>> I'm looking to tidy up things a bit by clearing out a lot of old code >>> and switching to using the internal DateTime functions. >>> >>> Information is stored in the databases UTC normalized, and we get >>> around the problem o

Re: [PHP] Using DateTimeZone

2008-12-04 Thread Lester Caine
Lester Caine wrote: Lester Caine wrote: I'm looking to tidy up things a bit by clearing out a lot of old code and switching to using the internal DateTime functions. Information is stored in the databases UTC normalized, and we get around the problem of getting a real tz offset by getting the

Re: [PHP] Using DateTimeZone

2008-12-04 Thread Lester Caine
Lester Caine wrote: I'm looking to tidy up things a bit by clearing out a lot of old code and switching to using the internal DateTime functions. Information is stored in the databases UTC normalized, and we get around the problem of getting a real tz offset by getting the users to register i

[PHP] Using DateTimeZone

2008-12-04 Thread Lester Caine
I'm looking to tidy up things a bit by clearing out a lot of old code and switching to using the internal DateTime functions. Information is stored in the databases UTC normalized, and we get around the problem of getting a real tz offset by getting the users to register it rather than simply