Finding out timezone from TimeZone offset

Hi,

I'm using JavaScript to find out the local time on client, setting it to a cookie.

I then retrieve the value in a JSP page to find out the correction necessary for adjusting the time (in UTC) to local time. The problem, however, is that JavaScript returns the Daylight Savings Offset and the Zone_offset as one total, making it impossible to find out what TimeZone this Offset maps to.

My utility class is using the myCalendarObj.setTimeZone (tz) to adjust the time stamp.

Any suggestions on how I could find out what TimeZone my offset maps to, or any other suggestion?

Regards,

Mark

[634 byte] By [markkantora] at [2007-9-27 23:11:04]
# 1
I think it may often be sufficient to get display name as "GMT + [timeoffset]."
fsato4a at 2007-7-7 14:57:30 > top of Java-index,Desktop,I18N...
# 2

And what to do with problem of Daylight Saving Time? Not all countries use it. For instance, try to get all TimeZone IDs for GMT +00:00...

For this moment, I see only 2 solution: write a little applet, that will be detect TimeZone of client or lets user to detect his location (like in "Settings" for this page - top right corner). But it's bad solutions.

Atronya at 2007-7-7 14:57:30 > top of Java-index,Desktop,I18N...