Chinese region picker, data provided by chinese_regions_db
Download the production version or the development version.
Checkout chinese_regions_db project, and dump the database into json format(visit the project for details), and Copy these JSON files into your project.
var regionPicker = new ChineseRegion.RegionPicker({
remote: '/json_files_path',
initialize: function(picker){
picker.pick('310102', function(regions, collections){
console.log(regions, collections);
})
}
});
Checkout this project and install dependencies:
cd chineserp & npm install
and type following command in your peoject directory to start a server:
node examples/server.js
then, open the examples page in your browser
http://localhost:8888/examples