获得徽章 7
赞了这篇沸点
制作一个多选的下拉框
"```html
<!DOCTYPE html>
<html lang=\"zh\">
<head>
<meta charset=\"UTF-8\">
<meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">
<title>多选下拉框</title>
<style>
.dropdown {
position: relative;
display: inline-block;
}
.dropdown-content {
display: none;
position: absolute;
background-color: #f9f9f9;
min-width: 160px;
box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
z-index: 1;
}
.dropdown-content label {
display: block;
padding: 8px 12px;
cursor: pointer;
}
.dropdown-content label:hover {
background-color: #f1f1f1;
}
.show {
display: block;
}
.selected {
background-color: #e0e0e0;
}
</style>
</head>
<body>

<div class=\"dropdown\">
<button onclick=\"toggleDropdown()\">选择选项</b
展开
1
下一页
个人成就
文章被点赞 22
文章被阅读 7,635
掘力值 473
收藏集
6
关注标签
6
加入于