This week's book giveaway is in the JavaScript forum.
We're giving away four copies of JavaScript Promises Essentials and have Rami Sarieddine on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes Getting system timezone in Javascript Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of JavaScript Promises Essentials this week in the JavaScript forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Getting system timezone in Javascript" Watch "Getting system timezone in Javascript" New topic
Author

Getting system timezone in Javascript

Sayantan Majumdar
Greenhorn

Joined: Sep 28, 2008
Posts: 16
Hi,

I want to know if I can get the system time zone in Javascript. I am able to get the timezone offset by calling getTimezoneOffset. But this gives me the difference between the local time and UTC. Is it possible to get the timezone ID (expanded/ short) like "US/Pacific" or "PST".

Thanks in advance.
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
This is what you have to work with: http://www.w3schools.com/jsref/jsref_obj_date.asp

Eric
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Getting system timezone in Javascript