Auto Detect TimeZone


#1

Hi guys, I just want to know how can I achiever to detect the browser/user timezone automatically… Thanks for the help…


#2

var d = new Date();
var n = d.toString().match(/([A-Z]+[±][0-9]+.*)/)[1]
console.log(n)
it returns something like "GMT-0500 (Eastern Standard Time)"
Is this what you want