<! DOCTYPE html PUBLIC "-// W3C // dtd html 4.01 Transitional // EN" "http://www.w3.org/TR/html4/loose.dtd">
<Html>
<Head>
<Meta http-equiv = "Content-Type" content = "text/html; charset = UTF-8">
<Title> 1 </title>
<Script type = "text/javascript" src = "lib/jquery-1.5.2.js"> </script>
<Style type = "text/css">
. Red {
Background: red;
}
. Green {
Background: green;
}
</Style>
<Script type = "text/javascript">
// $ (). Ready (function (){
/*
$ (Div> p). click (function (){
Alert ("selected ");
});
$ (Ul> li). hover (function (){
Certificate (this).css ("background", red );
}, Function (){
((This).css ("background", white );
});
$ (Ul> li: last). hover (function (){
$ (This). addClass (green );
});
$ (Ul). find (li). each (function (I ){
Certificate (this).html((this).html () + "Sam" + I );
});
$ (Li). not (: has ("div"). addClass ("red ");
*/
//? $ (Li). not ([div]). addClass ("red ");
// $ ("Li [name]" ).css ("background-color", "# eee ");
/*
$ ("A [href * = google]"). hover (function (){
$ (This). addClass (green );
});
*/
/*
$ (Ul). find ("li"). hover (function (){
Var li = $ (this). next ();
If (li. is (: visible )){
Li. slideUp ();
} Else {
Li. slideDown ();
}
});
*/
/*
$ (A). hover (function (){
$ (This). parent (div). addClass (green );
}, Function (){
$ (This). parent (div). removeClass (green );
});
*/
//});
$ (Function (){
// Alert ("this simple write! ");
// Code to execute when the DOM is ready
});
</Script>
</Head>
<Body>
<P> one </p>
<Div>
<P> two </p>
</Div>
<P> three </p>
<Ul>
<Li> I </li>
<Li> like </li>
<Li style = "display: no"> you </li>
<Li> OK
<Div> this is a div </div> </li>
<Li name = "hi"> have a name </li>
</Ul>
<Div>
<A href = "Googlewww.google.com"> Google </a> <br/> <a href = "Baiduwww.baidu.com"> Baidu </a>
<Br/> <a href = "Yahoowww.yahoo.com"> Yahoo </a> <br/>
</Div>
</Body>
</Html> <! DOCTYPE html PUBLIC "-// W3C // dtd html 4.01 Transitional // EN ""Http://www.w3.org/TR/html4/loose.dtd>
<Head>
<Meta http-equiv = "Content-Type" content = "text/html; charset = UTF-8">
<Title> </title>
<Script type = "text/javascript" src = "lib/jquery-1.5.2.js"> </script>
<Script type = "text/javascript" src = "lib/jquery. tablesorter. js"> </script>
<Style type = "text/css">
. Red {
Background: red;
}
. Green {
Background: green;
Display: none;
}
. Black {
Background: black;
}
. Yellow {
Background: yellow;
}
Div {
Width: 100px;
Height: 100px;
Font-size: 30px;
Font-family: serif;
}
</Style>
<Script type = "text/javascript">
$ (Function (){
/*
$ (Div [name * = div1]). addClass ("red"). end (). toggle (function (){
$ (Div [class * = yellow]). hide (slow );
}, Function (){
$ (Div [class * = yellow]). show (fast );
});
$ (Div [name * = div2]). addClass ("green ");
*/
/*
$ ("A"). toggle (function (){
$ ("Div [name * = div1]"). animate ({
Height: "hide ",
Opacity: hide
}, "Slow ");
}, Function (){
$ ("Div [name * = div2]"). animate ({
Height: "show ",
Opacity: show
}, "Slow ");
});
*/
$ (# Large). tableSorter ({
StripingRowClass: [odd, even],
StripRowStartUp: true
});
});
</Script>
</Head>
<Body>
<Div name = "div1" class = "red"> div1 </div>
<Div name = "div2" class = "green"> div2 </div>
<Div class = "yellow"> div3 </div>
<Div class = "black"> div4 </div>
<A href = "#"> toggle </a>
<Table id = "large" cellspacing = "0">
<Thead>