Layui provincial urban drop-down menu three-level linkage

  To use this function, you need to use the contents of the layui folder, so you can’t just put layui.css and layui.jsIntroduced, it must be obtained from the layui folder

  Display effect

  share picture

  Code section

DOCTYPE html>

<html >

<head >
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<title >layareatitle>
<link rel="stylesheet" href="./layui/css/layui.css">
head>

<body >
<div class="layui-form">
<div class="layui-form-item" id="area-picker">
<div class="layui-form-label">Addressdiv>
<div class="layui-input-inline" style="width: 200px;">
<select name="province" class="province-selector" data-value="Guangdong Province" lay-filter="province-1">
<option value="">Please select provinceoption>
select>
div>
<div class="layui-input-inline" style="width: 200px;">
<select name="city" class="city-selector" data-value="Shenzhen" lay-filter="city-1">
<option value="">Please select the cityoption>
select>
div>
<div class="layui-input-inline" style="width: 200px;">
<select name="county" class="county-selector" data-value="Longgang District" lay-filter="county-1">
<option value="">Please select the areaoption>
select>
div>
div>
div>
<script src="./layui/layui.js"> script>
<script >
//Configuration plugin Directory
layui.config({
base:
'./mods/'
, version:
'1.0'
});
//Generally written directly in a js file
layui.use(['layer' , ' span>form' , 'layarea'], function () {
var layer = layui .layer
, form
= layui.form
, layarea
= layui.layarea;

layarea.render({
elem:
'#area-picker',
change:
function (res) {
//Select result
console.log(res);
}
});
});
script>
body>

html>

DOCTYPE html>

<html >

<head >
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<title >layareatitle>
<link rel="stylesheet" href="./layui/css/layui.css">
head>

<body >
<div class="layui-form">
<div class="layui-form-item" id="area-picker">
<div class="layui-form-label">Addressdiv>
<div class="layui-input-inline" style="width: 200px;">
<select name="province" class="province-selector" data-value="Guangdong Province" lay-filter="province-1">
<option value="">Please select provinceoption>
select>
div>
<div class="layui-input-inline" style="width: 200px;">
<select name="city" class="city-selector" data-value="Shenzhen" lay-filter="city-1">
<option value="">Please select the cityoption>
select>
div>
<div class="layui-input-inline" style="width: 200px;">
<select name="county" class="county-selector" data-value="Longgang District" lay-filter="county-1">
<option value="">Please select the areaoption>
select>
div>
div>
div>
<script src="./layui/layui.js"> script>
<script >
//Configuration plugin Directory
layui.config({
base:
'./mods/'
, version:
'1.0'
});
//Generally written directly in a js file
layui.use(['layer' , ' span>form' , 'layarea'], function () {
var layer = layui .layer
, form
= layui.form
, layarea
= layui.layarea;

layarea.render({
elem:
'#area-picker',
change:
function (res) {
//Select result
console.log(res);
}
});
});
script>
body>

html>

WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 5712 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.