> -----Original Message-----
> From: Bill Moseley [mailto:[EMAIL PROTECTED]
> Sent: Friday, January 20, 2006 10:26 AM
> To: [email protected]
> Subject: Daylight Saving
>
> I have a zipcode table that lists the city, state, timezone offset (eg
> -5) and a flag indicating if the location uses daylight saving time
> for U.S. zipcodes. I don't have the Olson name in the table.
>
> How do I set the timezone in this case -- taking into account the dst
> settings?
It looks like DateTime::TimeZone doesn't support offsets with DST.
You could use a brute force approach where you choose a single Olson
name to go with each offset/dst combination.
e.g. (just guessing at these)
GMT-0500(DST) => America/New_York
GMT-0500 => America/Indiana/Indianapolis
GMT-0800(DST) => America/Los_Angeles
Then, put that Olson name in the table and use it.
It's not exactly elegant, but it'd probably get you what you want.
Philip