Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
All world timezones in an HTML select element
<select name="timezone_offset" id="timezone-offset" class="span5">
<option value="-12:00">(GMT -12:00) Eniwetok, Kwajalein</option>
<option value="-11:00">(GMT -11:00) Midway Island, Samoa</option>
<option value="-10:00">(GMT -10:00) Hawaii</option>
<option value="-09:50">(GMT -9:30) Taiohae</option>
<option value="-09:00">(GMT -9:00) Alaska</option>
<option value="-08:00">(GMT -8:00) Pacific Time (US &amp; Canada)</option>
<option value="-07:00">(GMT -7:00) Mountain Time (US &amp; Canada)</option>
<option value="-06:00">(GMT -6:00) Central Time (US &amp; Canada), Mexico City</option>
<option value="-05:00">(GMT -5:00) Eastern Time (US &amp; Canada), Bogota, Lima</option>
<option value="-04:50">(GMT -4:30) Caracas</option>
<option value="-04:00">(GMT -4:00) Atlantic Time (Canada), Caracas, La Paz</option>
<option value="-03:50">(GMT -3:30) Newfoundland</option>
<option value="-03:00">(GMT -3:00) Brazil, Buenos Aires, Georgetown</option>
<option value="-02:00">(GMT -2:00) Mid-Atlantic</option>
<option value="-01:00">(GMT -1:00) Azores, Cape Verde Islands</option>
<option value="+00:00" selected="selected">(GMT) Western Europe Time, London, Lisbon, Casablanca</option>
<option value="+01:00">(GMT +1:00) Brussels, Copenhagen, Madrid, Paris</option>
<option value="+02:00">(GMT +2:00) Kaliningrad, South Africa</option>
<option value="+03:00">(GMT +3:00) Baghdad, Riyadh, Moscow, St. Petersburg</option>
<option value="+03:50">(GMT +3:30) Tehran</option>
<option value="+04:00">(GMT +4:00) Abu Dhabi, Muscat, Baku, Tbilisi</option>
<option value="+04:50">(GMT +4:30) Kabul</option>
<option value="+05:00">(GMT +5:00) Ekaterinburg, Islamabad, Karachi, Tashkent</option>
<option value="+05:50">(GMT +5:30) Bombay, Calcutta, Madras, New Delhi</option>
<option value="+05:75">(GMT +5:45) Kathmandu, Pokhara</option>
<option value="+06:00">(GMT +6:00) Almaty, Dhaka, Colombo</option>
<option value="+06:50">(GMT +6:30) Yangon, Mandalay</option>
<option value="+07:00">(GMT +7:00) Bangkok, Hanoi, Jakarta</option>
<option value="+08:00">(GMT +8:00) Beijing, Perth, Singapore, Hong Kong</option>
<option value="+08:75">(GMT +8:45) Eucla</option>
<option value="+09:00">(GMT +9:00) Tokyo, Seoul, Osaka, Sapporo, Yakutsk</option>
<option value="+09:50">(GMT +9:30) Adelaide, Darwin</option>
<option value="+10:00">(GMT +10:00) Eastern Australia, Guam, Vladivostok</option>
<option value="+10:50">(GMT +10:30) Lord Howe Island</option>
<option value="+11:00">(GMT +11:00) Magadan, Solomon Islands, New Caledonia</option>
<option value="+11:50">(GMT +11:30) Norfolk Island</option>
<option value="+12:00">(GMT +12:00) Auckland, Wellington, Fiji, Kamchatka</option>
<option value="+12:75">(GMT +12:45) Chatham Islands</option>
<option value="+13:00">(GMT +13:00) Apia, Nukualofa</option>
<option value="+14:00">(GMT +14:00) Line Islands, Tokelau</option>
</select>
@alketii

This comment has been minimized.

Copy link

commented Sep 27, 2016

If someone needs it as sql

DROP TABLE IF EXISTS `timezones`;
CREATE TABLE `timezones` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `value` varchar(25) COLLATE utf8_unicode_ci NOT NULL,
  `label` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

INSERT INTO `timezones` (`id`, `value`, `label`) VALUES
(1, '-12:00',   '(GMT -12:00) Eniwetok, Kwajalein'),
(2, '-11:00',   '(GMT -11:00) Midway Island, Samoa'),
(3, '-10:00',   '(GMT -10:00) Hawaii'),
(4, '-09:50',   '(GMT -9:30) Taiohae'),
(5, '-09:00',   '(GMT -9:00) Alaska'),
(6, '-08:00',   '(GMT -8:00) Pacific Time (US &amp; Canada)'),
(7, '-07:00',   '(GMT -7:00) Mountain Time (US &amp; Canada)'),
(8, '-06:00',   '(GMT -6:00) Central Time (US &amp; Canada), Mexico City'),
(9, '-05:00',   '(GMT -5:00) Eastern Time (US &amp; Canada), Bogota, Lima'),
(10,    '-04:50',   '(GMT -4:30) Caracas'),
(11,    '-04:00',   '(GMT -4:00) Atlantic Time (Canada), Caracas, La Paz'),
(12,    '-03:50',   '(GMT -3:30) Newfoundland'),
(13,    '-03:00',   '(GMT -3:00) Brazil, Buenos Aires, Georgetown'),
(14,    '-02:00',   '(GMT -2:00) Mid-Atlantic'),
(15,    '-01:00',   '(GMT -1:00) Azores, Cape Verde Islands'),
(16,    '+00:00',   '(GMT) Western Europe Time, London, Lisbon, Casablanca'),
(17,    '+01:00',   '(GMT +1:00) Brussels, Copenhagen, Madrid, Paris'),
(18,    '+02:00',   '(GMT +2:00) Kaliningrad, South Africa'),
(19,    '+03:00',   '(GMT +3:00) Baghdad, Riyadh, Moscow, St. Petersburg'),
(20,    '+03:50',   '(GMT +3:30) Tehran'),
(21,    '+04:00',   '(GMT +4:00) Abu Dhabi, Muscat, Baku, Tbilisi'),
(22,    '+04:50',   '(GMT +4:30) Kabul'),
(23,    '+05:00',   '(GMT +5:00) Ekaterinburg, Islamabad, Karachi, Tashkent'),
(24,    '+05:50',   '(GMT +5:30) Bombay, Calcutta, Madras, New Delhi'),
(25,    '+05:75',   '(GMT +5:45) Kathmandu, Pokhar'),
(26,    '+06:00',   '(GMT +6:00) Almaty, Dhaka, Colombo'),
(27,    '+06:50',   '(GMT +6:30) Yangon, Mandalay'),
(28,    '+07:00',   '(GMT +7:00) Bangkok, Hanoi, Jakarta'),
(29,    '+08:00',   '(GMT +8:00) Beijing, Perth, Singapore, Hong Kong'),
(30,    '+08:75',   '(GMT +8:45) Eucla'),
(31,    '+09:00',   '(GMT +9:00) Tokyo, Seoul, Osaka, Sapporo, Yakutsk'),
(32,    '+09:50',   '(GMT +9:30) Adelaide, Darwin'),
(33,    '+10:00',   '(GMT +10:00) Eastern Australia, Guam, Vladivostok'),
(34,    '+10:50',   '(GMT +10:30) Lord Howe Island'),
(35,    '+11:00',   '(GMT +11:00) Magadan, Solomon Islands, New Caledonia'),
(36,    '+11:50',   '(GMT +11:30) Norfolk Island'),
(37,    '+12:00',   '(GMT +12:00) Auckland, Wellington, Fiji, Kamchatka'),
(38,    '+12:75',   '(GMT +12:45) Chatham Islands'),
(39,    '+13:00',   '(GMT +13:00) Apia, Nukualofa'),
(40,    '+14:00',   '(GMT +14:00) Line Islands, Tokelau');
@goatandsheep

This comment has been minimized.

Copy link

commented Jul 20, 2017

{type: Array,  
            value: [
                { name: "(GMT -12:00) Eniwetok, Kwajalein", value: "-12:00"},
                { name: "(GMT -11:00) Midway Island, Samoa", value: "-11:00"},
                { name: "(GMT -10:00) Hawaii", value: "-10:00"},
                { name: "(GMT -9:30) Taiohae", value: "-09:50"},
                { name: "(GMT -9:00) Alaska", value: "-09:00"},
                { name: "(GMT -8:00) Pacific Time (US &amp; Canada)", value: "-08:00"},
                { name: "(GMT -7:00) Mountain Time (US &amp; Canada)", value: "-07:00"},
                { name: "(GMT -6:00) Central Time (US &amp; Canada), Mexico City", value: "-06:00"},
                { name: "(GMT -5:00) Eastern Time (US &amp; Canada), Bogota, Lima", value: "-05:00"},
                { name: "(GMT -4:30) Caracas", value: "-04:50"},
                { name: "(GMT -4:00) Atlantic Time (Canada), Caracas, La Paz", value: "-04:00"},
                { name: "(GMT -3:30) Newfoundland", value: "-03:50"},
                { name: "(GMT -3:00) Brazil, Buenos Aires, Georgetown", value: "-03:00"},
                { name: "(GMT -2:00) Mid-Atlantic", value: "-02:00"},
                { name: "(GMT -1:00) Azores, Cape Verde Islands", value: "-01:00", selected="selected"},
                { name: "(GMT) Western Europe Time, London, Lisbon, Casablanca", value: "+00:00"},
                { name: "(GMT +1:00) Brussels, Copenhagen, Madrid, Paris", value: "+01:00"},
                { name: "(GMT +2:00) Kaliningrad, South Africa", value: "+02:00"},
                { name: "(GMT +3:00) Baghdad, Riyadh, Moscow, St. Petersburg", value: "+03:00"},
                { name: "(GMT +3:30) Tehran", value: "+03:50"},
                { name: "(GMT +4:00) Abu Dhabi, Muscat, Baku, Tbilisi", value: "+04:00"},
                { name: "(GMT +4:30) Kabul", value: "+04:50"},
                { name: "(GMT +5:00) Ekaterinburg, Islamabad, Karachi, Tashkent", value: "+05:00"},
                { name: "(GMT +5:30) Bombay, Calcutta, Madras, New Delhi", value: "+05:50"},
                { name: "(GMT +5:45) Kathmandu, Pokhara", value: "+05:75"},
                { name: "(GMT +6:00) Almaty, Dhaka, Colombo", value: "+06:00"},
                { name: "(GMT +6:30) Yangon, Mandalay", value: "+06:50"},
                { name: "(GMT +7:00) Bangkok, Hanoi, Jakarta", value: "+07:00"},
                { name: "(GMT +8:00) Beijing, Perth, Singapore, Hong Kong", value: "+08:00"},
                { name: "(GMT +8:45) Eucla", value: "+08:75"},
                { name: "(GMT +9:00) Tokyo, Seoul, Osaka, Sapporo, Yakutsk", value: "+09:00"},
                { name: "(GMT +9:30) Adelaide, Darwin", value: "+09:50"},
                { name: "(GMT +10:00) Eastern Australia, Guam, Vladivostok", value: "+10:00"},
                { name: "(GMT +10:30) Lord Howe Island", value: "+10:50"},
                { name: "(GMT +11:00) Magadan, Solomon Islands, New Caledonia", value: "+11:00"},
                { name: "(GMT +11:30) Norfolk Island", value: "+11:50"},
                { name: "(GMT +12:00) Auckland, Wellington, Fiji, Kamchatka", value: "+12:00"},
                { name: "(GMT +12:45) Chatham Islands", value: "+12:75"},
                { name: "(GMT +13:00) Apia, Nukualofa", value: "+13:00"},
                { name: "(GMT +14:00) Line Islands, Tokelau", value: "+14:00"}
            ]
        }
@mj1856

This comment has been minimized.

Copy link

commented Aug 30, 2017

Lists like these are dangerous.

  • They assume a time zone can be represented by a single numeric offset, which is incorrect.
  • They overlook that even time zones that share the same offset or set of offsets may use different transitions between standard time and daylight time (where applicable).
  • They often assume there is only one time zone that uses a particular offset, which is usually false.
  • They often are opinionated, omitting time zones that an individual didn't think were important.
  • They are rarely updated to reflect changes to time zones as they occur over the world.
  • The are often copied poorly from more reliable sources.

The only reliable sources of time zone information are:

  • The IANA time zone database, when the system is kept updated
  • The Microsoft Windows time zone database, from the June 2016 update forward, when the system is kept updated
  • Languages, platforms, libraries and APIs that derive from their data from the above two sources, when kept updated.

I am writing this here because this gist is referenced from several pages on the Internet that appear to be taking these lists as reliable sources of truth. They are in fact - not.

@jesraygarciano

This comment has been minimized.

Copy link

commented Feb 8, 2018

Thanks

@cccaldas

This comment has been minimized.

Copy link

commented Jul 4, 2018

+1

@ernestbangbuh

This comment has been minimized.

Copy link

commented Feb 1, 2019

Hi i have a table with many columns like cities, countries zip codes and others, i need to add a new column in an ssis package such that when i run the packed a new column called timezone automatically populates with the various times against the countries and cities. How do i achieve this??

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.