checkbox全选<head></head>
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
var checkflag = "false";
function check(field) {
if (checkflag == "false") {
for (i = 0; i < field.length; i++) {
field[i].checked = true;}
checkflag = "true";
return "false"; }
else {
for (i = 0; i < field.length; i++) {
field[i].checked = false; }
checkflag = "false";
return "true"; }
}
// End -->
</script>
<body></body>
<form name="form" method="post" action="">
<input type="checkbox" name="list" value="1">
<input type="checkbox" name="list" value="2">
<input type="checkbox" name="list" value="3">
<input type=checkbox value="全选" onClick="this.value=check(this.form.list)">
选中所有显示记录