The website development often involves the registration, the registration usually will have the district Cascade request. as shown below. To do this, you have to have data support. Yesterday, a day of hard work, from the Internet to tinker with a copy of the data. Share next. Pure technical sharing, non-profit. If there is infringement of the place please notify, immediately delete.
I don't know how to upload the attachment, I put the link directly
1. Data of provinces and cities (15k)
Address: Http://www1.pcauto.com.cn/zt/pcauto20160111/areaData/proCity.js
1. Data of provinces and cities (172k)
Address: Http://www1.pcauto.com.cn/zt/pcauto20160111/areaData/proCityCountry.js
2. Data of provinces, cities and counties (1545k)
Address: Http://www1.pcauto.com.cn/zt/pcauto20160111/areaData/proCityCountryTown.js
The following data are organized into separate files for easy combination use
3, Province (1k)
Address: Http://www1.pcauto.com.cn/zt/pcauto20160111/areaData/pro.js
4. City (14k)
Address: Http://www1.pcauto.com.cn/zt/pcauto20160111/areaData/city.js
5, county (159k)
Address: Http://www1.pcauto.com.cn/zt/pcauto20160111/areaData/country.js
6. Township data (1373k)
Address: Http://www1.pcauto.com.cn/zt/pcauto20160111/areaData/town.js
When the level to the township when the data is very large, there are more than 1m, you should not put the JS file load in one time, this will slow down the load times of the page, the use of sub-load is better. For example, loading the procitycountry.js first, loading the page after loading the town.js, of course, this is only a preliminary optimization, but also to optimize more. The above is only a reference to the opinion, you use the case.
Demo:http://www1.pcauto.com.cn/zt/pcauto20160111/areaData/areaDataOther.html
Provincial and Municipal counties and cities of the town cascade data JS version