- xml - AJAX/Jquery XML 解析
- 具有多重继承的 XML 模式
- .net - 枚举序列化 Json 与 XML
- XML 简单类型、简单内容、复杂类型、复杂内容
我正在使用 moment.js(我使用的方法是 moment.tz.names()
)来检索时区名称列表,该列表列举了全局 500 多个城市。长列表使得用户选择所需时区的效率不高。问题是是否有办法减少列表的大小,这意味着将同一时区偏移的城市分组在一起。
最佳答案
这是 Microsoft Time Zone Index Values ,在此处的另一个答案中提到 @stanleyxu2005 .
{000, "Dateline Standard Time", "(GMT-12:00) International Date Line West"},
{001, "Samoa Standard Time", "(GMT-11:00) Midway Island, Samoa"},
{002, "Hawaiian Standard Time", "(GMT-10:00) Hawaii"},
{003, "Alaskan Standard Time", "(GMT-09:00) Alaska"},
{004, "Pacific Standard Time", "(GMT-08:00) Pacific Time (US and Canada); Tijuana"},
{010, "Mountain Standard Time", "(GMT-07:00) Mountain Time (US and Canada)"},
{013, "Mexico Standard Time 2", "(GMT-07:00) Chihuahua, La Paz, Mazatlan"},
{015, "U.S. Mountain Standard Time", "(GMT-07:00) Arizona"},
{020, "Central Standard Time", "(GMT-06:00) Central Time (US and Canada"},
{025, "Canada Central Standard Time", "(GMT-06:00) Saskatchewan"},
{030, "Mexico Standard Time", "(GMT-06:00) Guadalajara, Mexico City, Monterrey"},
{033, "Central America Standard Time", "(GMT-06:00) Central America"},
{035, "Eastern Standard Time", "(GMT-05:00) Eastern Time (US and Canada)"},
{040, "U.S. Eastern Standard Time", "(GMT-05:00) Indiana (East)"},
{045, "S.A. Pacific Standard Time", "(GMT-05:00) Bogota, Lima, Quito"},
{050, "Atlantic Standard Time", "(GMT-04:00) Atlantic Time (Canada)"},
{055, "S.A. Western Standard Time", "(GMT-04:00) Caracas, La Paz"},
{056, "Pacific S.A. Standard Time", "(GMT-04:00) Santiago"},
{060, "Newfoundland and Labrador Standard Time", "(GMT-03:30) Newfoundland and Labrador"},
{065, "E. South America Standard Time", "(GMT-03:00) Brasilia"},
{070, "S.A. Eastern Standard Time", "(GMT-03:00) Buenos Aires, Georgetown"},
{073, "Greenland Standard Time", "(GMT-03:00) Greenland"},
{075, "Mid-Atlantic Standard Time", "(GMT-02:00) Mid-Atlantic"},
{080, "Azores Standard Time", "(GMT-01:00) Azores"},
{083, "Cape Verde Standard Time", "(GMT-01:00) Cape Verde Islands"},
{085, "GMT Standard Time", "(GMT) Greenwich Mean Time: Dublin, Edinburgh, Lisbon, London"},
{090, "Greenwich Standard Time", "(GMT) Casablanca, Monrovia"},
{095, "Central Europe Standard Time", "(GMT+01:00) Belgrade, Bratislava, Budapest, Ljubljana, Prague"},
{100, "Central European Standard Time", "(GMT+01:00) Sarajevo, Skopje, Warsaw, Zagreb"},
{105, "Romance Standard Time", "(GMT+01:00) Brussels, Copenhagen, Madrid, Paris"},
{110, "W. Europe Standard Time", "(GMT+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna"},
{113, "W. Central Africa Standard Time", "(GMT+01:00) West Central Africa"},
{115, "E. Europe Standard Time", "(GMT+02:00) Bucharest"},
{120, "Egypt Standard Time", "(GMT+02:00) Cairo"},
{125, "FLE Standard Time", "(GMT+02:00) Helsinki, Kiev, Riga, Sofia, Tallinn, Vilnius"},
{130, "GTB Standard Time", "(GMT+02:00) Athens, Istanbul, Minsk"},
{135, "Israel Standard Time", "(GMT+02:00) Jerusalem"},
{140, "South Africa Standard Time", "(GMT+02:00) Harare, Pretoria"},
{145, "Russian Standard Time", "(GMT+03:00) Moscow, St. Petersburg, Volgograd"},
{150, "Arab Standard Time", "(GMT+03:00) Kuwait, Riyadh"},
{155, "E. Africa Standard Time", "(GMT+03:00) Nairobi"},
{158, "Arabic Standard Time", "(GMT+03:00) Baghdad"},
{160, "Iran Standard Time", "(GMT+03:30) Tehran"},
{165, "Arabian Standard Time", "(GMT+04:00) Abu Dhabi, Muscat"},
{170, "Caucasus Standard Time", "(GMT+04:00) Baku, Tbilisi, Yerevan"},
{175, "Transitional Islamic State of Afghanistan Standard Time", "(GMT+04:30) Kabul"},
{180, "Ekaterinburg Standard Time", "(GMT+05:00) Ekaterinburg"},
{185, "West Asia Standard Time", "(GMT+05:00) Islamabad, Karachi, Tashkent"},
{190, "India Standard Time", "(GMT+05:30) Chennai, Kolkata, Mumbai, New Delhi"},
{193, "Nepal Standard Time", "(GMT+05:45) Kathmandu"},
{195, "Central Asia Standard Time", "(GMT+06:00) Astana, Dhaka"},
{200, "Sri Lanka Standard Time", "(GMT+06:00) Sri Jayawardenepura"},
{201, "N. Central Asia Standard Time", "(GMT+06:00) Almaty, Novosibirsk"},
{203, "Myanmar Standard Time", "(GMT+06:30) Yangon Rangoon"},
{205, "S.E. Asia Standard Time", "(GMT+07:00) Bangkok, Hanoi, Jakarta"},
{207, "North Asia Standard Time", "(GMT+07:00) Krasnoyarsk"},
{210, "China Standard Time", "(GMT+08:00) Beijing, Chongqing, Hong Kong SAR, Urumqi"},
{215, "Singapore Standard Time", "(GMT+08:00) Kuala Lumpur, Singapore"},
{220, "Taipei Standard Time", "(GMT+08:00) Taipei"},
{225, "W. Australia Standard Time", "(GMT+08:00) Perth"},
{227, "North Asia East Standard Time", "(GMT+08:00) Irkutsk, Ulaanbaatar"},
{230, "Korea Standard Time", "(GMT+09:00) Seoul"},
{235, "Tokyo Standard Time", "(GMT+09:00) Osaka, Sapporo, Tokyo"},
{240, "Yakutsk Standard Time", "(GMT+09:00) Yakutsk"},
{245, "A.U.S. Central Standard Time", "(GMT+09:30) Darwin"},
{250, "Cen. Australia Standard Time", "(GMT+09:30) Adelaide"},
{255, "A.U.S. Eastern Standard Time", "(GMT+10:00) Canberra, Melbourne, Sydney"},
{260, "E. Australia Standard Time", "(GMT+10:00) Brisbane"},
{265, "Tasmania Standard Time", "(GMT+10:00) Hobart"},
{270, "Vladivostok Standard Time", "(GMT+10:00) Vladivostok"},
{275, "West Pacific Standard Time", "(GMT+10:00) Guam, Port Moresby"},
{280, "Central Pacific Standard Time", "(GMT+11:00) Magadan, Solomon Islands, New Caledonia"},
{285, "Fiji Islands Standard Time", "(GMT+12:00) Fiji Islands, Kamchatka, Marshall Islands"},
{290, "New Zealand Standard Time", "(GMT+12:00) Auckland, Wellington"},
{300, "Tonga Standard Time", "(GMT+13:00) Nuku'alofa"}
关于javascript - 如何缩短从 moment.js 获取的时区名称列表?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35912452/
这个问题在这里已经有了答案: 关闭 11 年前。 Possible Duplicate: How do short URLs services work? 我经常看到来自 bitly.com 的缩短
if (args.join(" ").toLowerCase() === "are you" || args.join(" ").toLowerCase() === "are you doing")
学习Golang,想知道是否有更短的编写方法 if tiletype == 0 || tiletype == 2 { levelmap[pass
sum_num = 0 for human in humans: sum_num += human.limbs return sum_num 假设对象 human 具有属性 limbs ,如下
我想问一下是否有一种方法可以像在 MSSQL 中那样缩短这个条件,因为我也有类似的条件。 if(docType == "PO" || docType == "II" || docType == "IA
关闭。这个问题需要更多focused .它目前不接受答案。 想改进这个问题吗? 更新问题,使其只关注一个问题 editing this post . 关闭 3 年前。 Improve this qu
我在单页上有一些 15-20 个 Highcharts (使用 slider ,每张幻灯片 1-2 个图表)、一些条形图、一些柱形图、一些饼图,具有不同的显示选项。我使用的是在我的闭包内有多种方法,其
几周前,我在下拉菜单的一些代码上得到了一些帮助,但我想知道是否可以使代码更短,因为下面显示的当前代码相当大,任何帮助都会很棒。 $(document).ready(function(){ $(
这里是新的。我只是想知道是否有可能使这个 if 语句更短且冗余更少。 if (!a && b) { if (c == d && e > 0) { return;
我有这个代码。 c = getch() if c == "r":
我有几行代码用于迭代列表中的字典,我想缩短它。它按原样完美运行,但似乎代码太多,我正在尝试了解如何在 Python 中(或一般情况下)保持代码高效。 for d in dev['devices']:
如果代码如下,如何缩短 if 语句? $a = null; $b = "foo"; if ((empty($a) && !empty($b)) || (!empty($a) && empty($b))
我需要计算应用的每日独立用户数。 我可以唯一识别用户的唯一方法是通过他们的 UUID(这是外部提供的,所以我不得不使用它)。 我知道我的每日用户数是几百万。 我想在 Redis 中使用一个 bitse
载体 a和 b可以使用 toString(width = 10) 缩短在 Base R 中导致以 .... 结尾的较短向量 但是,我想知道如何使缩短的向量以 ..., last vector elem
是否有缩短 HTML 页面的库(最好是 Python 库)?我的意思是它会生成一个可能更小的(就字符数而言,包括换行符 Silly example 可以改成: Silly example
如何缩短这段 CSS 的代码?当它在移动 View 中时,它将隐藏表格的某些列。我的表有 137 列,我只想查看 5 列。 @media only screen and (max-width: 800
我所拥有的是主目录中的文件路径,我希望将其处理为包含“~”的缩短路径。 例如,我的输入可能是:"/home/username/test"或 /home/./username/test或 /home/.
我们为文档生成一个 GUID,并且需要将该 GUID 包含在 C40 编码的条码(Type 29 2D)中,并且具有以下限制。 最长可达 25 个字符只能使用大写字母数字字符,不能使用特殊字符。 我曾
这个问题已经有答案了: Ternary operators in JavaScript without an "else" (13 个回答) 已关闭 4 年前。 我一直使用这样的三元表达式,但我不喜欢
首先,我想确保我知道这样一个事实:重新哈希是一个明智的话题。不过,我想听听您的一些意见,以及您会采取什么方法。 我正在构建一个分布式应用程序,其中节点远程创建由 UUID 标识的实体。最终,所有实体应
我是一名优秀的程序员,十分优秀!