Javascript or JQuery Function to get All TimeZones to Display in DOJO Combobox?

383 views Asked by At

Is there any default or custom function to display all timezones combo box in DOJO using ItemFileReadStore?

1

There are 1 answers

2
murli2308 On

No. There is no function in JS to get all the time zones. Only thing you get is time zone offset bye following code.

var date = new Date(),
    zoneOffset = date.getTimezoneOffset();

And in dojo you can get name of timezone

require(["dojo/date"], function(date){
  var myDate = (2000, 5, 16);
  date.getTimezoneName(myDate);
 });

I have used in past http://momentjs.com/timezone/data/ JS but it is currently under development again.