js取消radio选中 反选

var radio=document.createElement("input");
radio.type="radio";
radio.onclick = function(){
if (this.tag==1){
this.checked=false;
this.tag=0;
}
else{
this.checked=true;
this.tag=1
}
};

posted on 2016-11-04 17:26  web369  阅读(544)  评论(0编辑  收藏  举报

导航