js:
function checkAll(name)> el = document.getElementsByTagName('輸入');
var len = el.length;
for(var i=0; iif((el[i].type =="checkbox") && (el[i].name==name)){
el[i].checked = true;
}
}
}
functionclearAll(name ) {
var el = document.getElementsByTagName('input');
var len = el.length;
for(var i=0; iif(( el[i].type=="checkbox") && (el[i].name==name)){
el[i].checked = false;
}
}
}
html:
全選
;