<! Doctype HTML public "-// W3C // dtd xhtml 1.0 transitional // en" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<HTML xmlns = "http://www.w3.org/1999/xhtml">
<Head>
<Meta http-equiv = "Content-Type" content = "text/html; charset = UTF-8"/>
<SCRIPT src = "jquery. js" type = "text/JavaScript"> </SCRIPT>
<Title> untitled document </title>
<Style type = "text/CSS">
Table {
Border-collapse: collapse;
Font-size: 12px;
}
TD {
Border: 1px solid # CCC;
Padding-left: 5px;
}
. Alt {
Background: # EfE;
}
. Over {
Background: # Eef;
}
. Selected {
Background: # 0ff;
}
</Style>
<SCRIPT type = "text/JavaScript">
<! --
$ (document ). ready (function () {
$ (". list TR: Even "). addclass ("Alt");
$ (". list TR "). mouseover (function () {$ (this ). addclass ("over ")}). mouseout (function () {$ (this ). removeclass ("over ")}). click (
function () {
if ($ (this ). hasclass ("selected")
{< BR >$ (this ). removeclass ("selected");
$ (this ). find ("input [type = 'checkbox']"). removeattr ("checked");
}< br> else
{< BR >$ (this ). addclass ("selected");
$ (this ). find ("input [type = 'checkbox']"). ATTR ("checked", "true");
}< BR >});
$ ("# All"). Click (function (){
If ($ ("# All"). ATTR ("checked "))
{
$ ("Input: checkbox [name = 'box']"). ATTR ("checked", true );
}
Else
{
$ ("Input: checkbox [name = 'box']"). ATTR ("checked", false );
}
});
}
);
// -->
</SCRIPT>
</Head>
<Body>
<Form ID = "form1" name = "form1" method = "Post" Action = "">
<Table id = "list" width = "1026" Height = "156" cellpadding = "0" cellspacing = "0">
<Thead>
<Tr>
<TD width = "100"> <input type = "checkbox" id = "all"/> <label for = "all"> select all </label> </TD>
<TD width = "414"> title </TD>
<TD width = "233"> recipient </TD>
<TD width = "251"> date </TD>
</Tr>
</Thead>
<Tbody class = "list">
<Tr>
<TD width = "50"> <input type = "checkbox" name = "box" value = "1"/> </TD>
<TD width = "464"> & nbsp; </TD>
<TD> & nbsp; </TD>
<TD> & nbsp; </TD>
</Tr>
<Tr>
<TD> <input type = "checkbox" name = "box" value = "2"/> </TD>
<TD> & nbsp; </TD>
<TD> & nbsp; </TD>
<TD> & nbsp; </TD>
</Tr>
<Tr>
<TD> <input type = "checkbox" name = "box" value = "5"/> </TD>
<TD> & nbsp; </TD>
<TD> & nbsp; </TD>
<TD> & nbsp; </TD>
</Tr>
</Tbody>
</Table>
</Form>
</Body>
</Html>