当前位置:网站首页>Select drop-down box realizes three-level linkage of provinces and cities in China
Select drop-down box realizes three-level linkage of provinces and cities in China
2022-07-05 12:07:00 【**inevitable**】
JS Select The drop-down box realizes the three-level linkage of provinces and cities in China
Linkage effect
Take Inner Mongolia Autonomous Region as an example 


distpicker.js The resource acquisition
https://pan.baidu.com/s/1S17KyRmPfz6WYaYUV1kkuw
Extraction code :7rjv
HTML structure
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<title> Multi level linkage in urban areas of China </title>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
crossorigin="anonymous">
<style>
.test {
border: 1px solid red;
width: 600px;
height: 100px;
margin: 200px 450px;
}
.form-inline {
margin-left: 35px;
margin-top: 25px;
}
</style>
</head>
<body>
<div class="test">
<form class="form-inline">
<div data-toggle="distpicker">
<select class="form-control" data-province="---- Select Province ----"></select>
<select class="form-control" data-city="---- Choose the city ----"></select>
<select class="form-control" data-district="---- Selection area ----"></select>
</div>
</form>
</div>
<!-- Scripts -->
<script src="https://code.jquery.com/jquery-3.4.1.slim.min.js" crossorigin="anonymous"></script>
<script src="./js/distpicker.js"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.bundle.min.js" crossorigin="anonymous">
</script>
</body>
</html>
Pay attention to the introduction of distpicker.js The path of , Just change to your own path
边栏推荐
猜你喜欢

Seven ways to achieve vertical centering

11. (map data section) how to download and use OSM data

Course design of compilation principle --- formula calculator (a simple calculator with interface developed based on QT)

redis主从模式

Matlab imoverlay function (burn binary mask into two-dimensional image)

Matlab superpixels function (2D super pixel over segmentation of image)

Multi table operation - sub query

【主流Nivida显卡深度学习/强化学习/AI算力汇总】

Uniapp + unicloud + Unipay realize wechat applet payment function

Check the debug port information in rancher and do idea remote JVM debug
随机推荐
Halcon template matching actual code (I)
[pytorch modifies the pre training model: there is little difference between the measured loading pre training model and the random initialization of the model]
Solve readobjectstart: expect {or N, but found n, error found in 1 byte of
Codeforces Round #804 (Div. 2)
splunk配置163邮箱告警
Ncp1342 chip substitute pn8213 65W gallium nitride charger scheme
redis的持久化机制原理
byte2String、string2Byte
Principle of redis cluster mode
The solution of outputting 64 bits from printf format%lld of cross platform (32bit and 64bit)
Check the debug port information in rancher and do idea remote JVM debug
1 plug-in to handle advertisements in web pages
1个插件搞定网页中的广告
13. (map data) conversion between Baidu coordinate (bd09), national survey of China coordinate (Mars coordinate, gcj02), and WGS84 coordinate system
Uniapp + unicloud + Unipay realize wechat applet payment function
想问问,如何选择券商?在线开户是很安全么?
Complete activity switching according to sliding
[mainstream nivida graphics card deep learning / reinforcement learning /ai computing power summary]
[cloud native | kubernetes] actual battle of ingress case (13)
Seven ways to achieve vertical centering