谢谢
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.
<html xmlns="http://www.
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
<script language="javascript">
function selected(bool)
{
var check=document.getElementsByName("head");
for(var i=0;i<check.length;i++)
{
if(check[i].type="checkbox")
{
check[i].checked=bool;
}
}
}
</script>
</head>
<body>
<form name="form">
<table width="339" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="157" align="center"><input name="button" type="button" onclick="selected(true)" value="全
选"/>
<br />
<input type="button"
value="全不选" onclick="selected(false)"/>
</td><td width="94">类型</td>
<td width="74">数量</td>
</tr>
<tr>
<td><input type="checkbox" name="head"/></td>
<td>西游记</td>
<td>50.00</td>
</tr>
<tr>
<td><input type="checkbox" name="head"/></td>
<td>红楼梦</td>
<td>100.00</td>
</tr>
</table>
</form>
</body>
</html>
我只要这些就可以了。