单选框只可以选中,取消需要点击其他单选框。 解决方案: <!DOCTYPE HTML>单选按钮取消选中$(function(){ $('input:radio').click(function(){ var domName = $(this).attr('name'); var $radio = $(this); // if this was previously checked if ($radio.data('waschecked') == true){ $radio.pro...
var domName = $(this).attr('name'); var $radio = $(this); // if this was previously checked if ($radio.data('waschecked') == true){ $radio.prop('checked', false); $("input:radio[name='" + domName + "']").data('waschecked',false); //$radio.data('waschecked', false)...
var domName = $(this).attr('name'); var $radio = $(this); // if this was previously checked if ($radio.data('waschecked') == true){ $radio.prop('checked', false); $("input:radio[name='" + domName + "']").data('waschecked',false); //$radio.data('waschecked', false)...
var domName = $(this).attr('name'); var $radio = $(this); // if this was previously checked if ($radio.data('waschecked') == true){ $radio.prop('checked', false); $("input:radio[name='" + domName + "']").data('waschecked',false); //$radio.data('waschecked', false)...