2 回答
TA贡献1868条经验 获得超4个赞
给每行单选按钮一个不同的名字
<div class="row">
<input type="radio" name="rowA" /> Label A
<input type="radio" name="rowA" /> Label B
<input type="radio" name="rowA" /> Label C
<input type="radio" name="rowA" /> Label D
</div>
<div class="row">
<input type="radio" name="rowB" /> Label A
<input type="radio" name="rowB" /> Label B
<input type="radio" name="rowB" /> Label C
<input type="radio" name="rowB" /> Label D
</div>
TA贡献1909条经验 获得超7个赞
javascript代码
<script src="https://code.jquery.com/jquery-2.2.4.js"></script>
$(document).on('click','.radio-class',function(){
$this = $(this);
// uncheck all other radio inputs except this one
$('.radio-class').not($this).prop('checked', false);
});
单选按钮
<asp:RadioButton ID="RadioButton1" GroupName="radio-class" runat="server" />
添加回答
举报