<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>全选禁用与取消</title>
<script language="javascript">
function checkall(form)
{
for(var i=0;i<form.elements.length-2;i++)
{
var e=form.elements[i];
if(e.type=='radio')
e.disabled=form.radio[0].checked;
}
}
</script>
</head>
<body>
<center>
<form name="myForm">
<input type="radio" name="box" value="1">1
<input type="radio" name="box" value="2">2
<input type="radio" name="box" value="3">3
<input type="radio" name="box" value="4">4
<input type="radio" name="box" value="5">5
<p> </p>
<input type="radio" name="radio" value="禁用" onClick="checkall(this.form);">
<input type="radio" name="radio" value="重置" onClick="checkall(this.form)">
</form>
</center>
</body>
</html>