pycountry provides the ISO databases for the standards:
639 Languages
3166 Countries
3166-2 Subdivisions of countries
4217 Currencies
15924 Scripts
The databases are imported from Debian's pkg-isocodes, packaged into pycountry and made accessible through a Python API.
Translation files for the various strings are included as well.
pycountry is the most complete free reference I was ever able to find:
pycountry provides the ISO databases for the standards:
639 Languages
3166 Countries
3166-2 Subdivisions of countries
4217 Currencies
15924 Scripts
The databases are imported from Debian's pkg-isocodes, packaged into pycountry and made accessible through a Python API.
Translation files for the various strings are included as well.
This list is rather old, however it does offer a great deal of value for those wanting a country list, with codes and abbreviations. Also, there is a link to US States and provinces there too. This has been a good resource over the years.
With this table data, it's possible for someone to create some normalized data between countries, states, provinces, counties or whatever political jurisdictions.
I thought this would be a huge time saver for this task.
发布评论
评论(6)
pycountry 是我能找到的最完整的免费参考:
pycountry is the most complete free reference I was ever able to find:
从 Geonames 获取数据是一种选择。它保持相对最新状态,并采用 CC 许可证。
Grabbing data from Geonames would be an option. It is kept relatively up to date, and is under a CC license.
我没有代码可以做到这一点,但如果您想要世界大部分地区的行政区的良好(免费)列表,您可以使用 此维基百科页面。
I don't have code to do it, but if you want a good (free) list of administrative districts for most of the world you can use this Wikipedia page.
正如 Squeeks 所说,您可以使用 GeoNames。
我做了一个工具( https://github.com/yosoyadri/GeoNames-XML-Builder ),根据 http://geonamesdotorgdotnet.codeplex.com/< 上的库下载 GeoNames 响应并将其保存为 XML 文件/a>.
您还可以在 https://raw.github.com/yosoyadri/GeoNames-XML-Builder/master/Continues-countries-statesprovinces.xml
As Squeeks says you can use GeoNames.
I did a tool ( https://github.com/yosoyadri/GeoNames-XML-Builder ) that downloads and saves GeoNames response as a XML file based on the library at http://geonamesdotorgdotnet.codeplex.com/.
You can also download a complete file of countries and states/provinces at https://raw.github.com/yosoyadri/GeoNames-XML-Builder/master/continents-countries-statesprovinces.xml
如果你不想使用 sql,这里只是一个带有地区国家的省/州的 JavaScript,我不久前发现了它。也许它很有用......
http: //www.sitepoint.com/forums/showthread.php?350291-Country-State-City-Dropdown-list
In case you don't want to use sql, here is just a javascript with region country's province/state, i found it a while ago. Maybe its of good use....
http://www.sitepoint.com/forums/showthread.php?350291-Country-State-City-Dropdown-list
这已经是最接近的了。
http://27.org/isocountrylist/
这个列表相当旧,但它确实提供了很多东西对于那些想要包含代码和缩写的国家/地区列表的人来说很有价值。此外,还有与美国各州和省份的链接。多年来,这一直是一个很好的资源。
利用此表数据,某人可以在国家、州、省、县或任何政治管辖区之间创建一些标准化数据。
我认为这将为这项任务节省大量时间。
This is as close as it gets.
http://27.org/isocountrylist/
This list is rather old, however it does offer a great deal of value for those wanting a country list, with codes and abbreviations. Also, there is a link to US States and provinces there too. This has been a good resource over the years.
With this table data, it's possible for someone to create some normalized data between countries, states, provinces, counties or whatever political jurisdictions.
I thought this would be a huge time saver for this task.