<! doctype>table{Border:#999 1px solid;Border-collapse:collapse; } table th{Text-align:Center; } Table td{Border: 1px solid#999;Text-align:Center; } .one{Background:#6CF; } .two{Background:#Fc6; } </style> <script type= "Text/javascript" language= "JavaScript" >functionChangeColor () {varTr=document.getelementsbytagname ("tr"); tr[0].style.background= "#0066ff"; Tr[tr. length-1].style.background= "#0066ff"; } functionChangebox (type) {varTBS = document.getElementById ("TBS"); varCHKS = tbs.getelementsbytagname ("Input"); Switch(type) { Case"QX": for(vari = 0; i < chks.length; i++) {Chks[i]. checked =true; } Break; Case"Qxx": for(vari = 0; i < chks.length; i++) {Chks[i]. checked =false; } Break; Case"FX": for(vari = 0; i < chks.length; i++) { if(chks[i].checked = =true) {Chks[i]. checked =false; } Else{Chks[i]. checked =true; } } Break; } } functiondel () {varInput=document.getelementsbyname ("check[")); for(varI=input.length-1; i>=0; i--){ if(input[i].checked==true){ varTd=input[i].parentnode; varTr=td.parentnode; varTable=tr.parentnode; Table.removechild (TR); } } } </script>class= "One" > <td><input type= "checkbox" Name= "check[" "></td> <td> Wang Dali </td> <td>[email protected]</td> <td> personal email </td> </tr> <trclass= "Both" > <td><input type= "checkbox" Name= "check[" "></td> <td> Wang Dali </td> <td>[email protected]</td> <td> personal email </td> </tr> <trclass= "One" > <td><input type= "checkbox" Name= "check[" "></td> <td> Wang Dali </td> <td>[email protected]</td> <td> personal email </td> </tr> <trclass= "Both" > <td><input type= "checkbox" Name= "check[" "></td> <td> Wang Dali </td> <td>[email protected]</td> <td> personal email </td> </tr> <trclass= "One" > <td><input type= "checkbox" Name= "check[" "></td> <td> Wang Dali </td> <td>[email protected]</td> <td> personal email </td> </tr> <trclass= "Both" > <td><input type= "checkbox" Name= "check[" "></td> <td> Wang Dali </td> <td>[email protected]</td> <td> personal email </td> </tr> <trclass= "One" > <td><input type= "checkbox" Name= "check[" "></td> <td> Wang Dali </td> <td>[email protected]</td> <td> personal email </td> </tr> <tr> <th> Options </ Th> <td colspan= "3" align= "center" > <input type= "button" id= "QX" onclick= "Changebox (' qx ')" value= "Select All "> <input type=" button "id=" Qxx "onclick=" Changebox (' Qxx ') "value=" deselect All "> <input type=" button "I D= "FX" onclick= "Changebox (' FX ')" value= "Reverse Selection" > <input type= "button" id= "del" onclick= "del ()" value= "Delete selected accessory" > </td> </tr> </tbody></table></body>PHP bulk operation of the table, such as the Select all anti-select Delete function