For some reason, when I pass a date with the time zone of Hawaii to JavaScript Date() , I get an "invalid date", but in any other time zone I do not. Is there a workaround for this?
var HAST = 'Wed, 31 Jul 2013 07:21:16 HAST'; var hawaiiTime = new Date(HAST); console.log("Hawaii time: "+hawaiiTime); // Hawaii time: Invalid Date var PST = 'Wed, 31 Jul 2013 07:21:16 PST'; var pacificTime = new Date(PST); console.log("Pacific time: "+pacificTime); // Pacific time: Wed Jul 31 2013 09:21:16 GMT-0600 (MDT)
jsFiddle
source share