亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定

兩個都選上的情況??

出現了兩個都選上的情況

<!DOCTYPE html>

<html>

<head>?

<meta charset="utf-8">

<title>屬性選擇器</title>

<link href="style.css" rel="stylesheet" type="text/css">

</head>?

<body>

<form action="#">

? <div class="wrapper">

? ? <div class="box">

? ? ? <input type="checkedbox" checked="checked" ?id="boy" name="1" /><span></span>

? ? </div>

? ? <label for="boy">男</label>

? </div>

??

? <div class="wrapper">

? ? <div class="box">

? ? ? <input type="checkbox" ?id="girl" name="1" ?/><span></span>

? ? </div>

? ? <label for="girl">女</label>

? </div>

</form>?

</body>

</html>

form {

? border: 1px solid #ccc;

? padding: 20px;

? width: 300px;

? margin: 30px auto;

}

.wrapper {

? margin-bottom: 10px;

}

.box {

? display: inline-block;

? width: 30px;

? height: 30px;

? margin-right: 10px;

? position: relative;

? background: orange;

? vertical-align: middle;

? border-radius: 100%;

}

.box input {

? opacity: 0;

? position: absolute;

? top:0;

? left:0;

? width: 100%;

? height:100%;

? z-index:100;/*使input按鈕在span的上一層,不加點擊區域會出現不靈敏*/

}


.box span {?

? display: block;

? width: 10px;

? height: 10px;

? border-radius: 100%;

? position: absolute;

? background: #fff;

? top: 50%;

? left:50%;

? margin: -5px 0 ?0 -5px;

? z-index:1;

}


input[type="radio"] + span {

? opacity: 0;


}

input[type="checkbox"]:chec


正在回答

2 回答

<input type="checkedbox">這個是多選框,所以當然可以二個都選上

單選框 是<input type="radio"/>

0 回復 有任何疑惑可以回復我~
#1

廣藿香Patchouli 提問者

后來是瀏覽器的問題- -
2015-10-10 回復 有任何疑惑可以回復我~

還有多選框是checkbox,不是checkedbox

0 回復 有任何疑惑可以回復我~
#1

廣藿香Patchouli 提問者

恩恩,改好了
2015-10-10 回復 有任何疑惑可以回復我~

舉報

0/150
提交
取消

兩個都選上的情況??

我要回答 關注問題
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號