Jquery selector (Comprehensive) and jquery selector Synthesis
<! 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> <title> simple selector </title> <meta http-equiv =" Content-Type "content =" text/html; charset = UTF-8 "/> <style type =" text/css ">. yang {border-collapse: collapse; width: 500px; height: 30px; border: 1px solid red; "} </style> <script type =" text/javascript "src =" jquery-1.7.1.min.js "> </script> <script type =" text/javascript "> /*: first // match the first element: last // match the last element: even // match the element with an even index (0 1 2 3 4 5 ): odd // match the element whose index is odd: eq (index) // match the element whose index is the specified value (Equal): gt (index) greater Than // Greater than: lt (index) Less Than // The element whose matching index is smaller than the specified value (Less Than Less than): not (selector) // match the elements other than the specified selector */window. onload = function () {$ ('# btnOk '). click (function () {$ ('table: last tr: even> td 'example .css ('color', 'red ');});}; </script>