<script src="/path/to/jquery.js"></script><!-- jQuery is required --> <script src="/path/to/city-picker.data.js"></script> <script src="/path/to/city-picker.js"></script>
<div style="position: relative;"><!-- container --> <input readonly type="text"> </div>
data-toggle="city-picker"
attribute<div data-toggle="city-picker"> <input readonly type="text" data-toggle="city-picker" > </div>
<div style="position: relative;"><!-- container --> <input readonly type="text" data-toggle="city-picker" placeholder="请选择省/市" data-level="city" > </div>
<div style="position: relative;"><!-- container --> <input readonly type="text" data-toggle="city-picker" placeholder="点击从下拉面板中选择省/市/区/县"> </div>
<div style="position: relative;"><!-- container --> <input readonly type="text" data-toggle="city-picker" data-simple="true" > </div>
<div style="position: relative;"><!-- container --> <input readonly type="text" data-toggle="city-picker" style="width:50%;"> </div>
<div style="position: relative;"><!-- container --> <input readonly type="text" data-toggle="city-picker" value="广东/广州市/番禺区/石楼镇"> </div>
The districts must be existed in the city-picker.data.js file!
$.fn.citypicker
method<div style="position: relative;"><!-- container --> <input id="city-picker1" readonly type="text"> </div>
$("#city-picker1").citypicker();
<div style="position: relative;"><!-- container --> <input id="city-picker2" readonly type="text"> </div>
$("#city-picker2").citypicker({ province: "广东", city: "广州市", district: "番禺区", district: "石楼镇" });
The districts must be existed in the city-picker.data.js file!