zoukankan      html  css  js  c++  java
  • jquery 遍历页面 class为xxx的td

     
    <script type="text/javascript"> 
     
    $(function () {
                 $("td.gname").each(function () {
                   //$(this).text()
                   //某些操作
                 });
     
           });
     </script>
     
    

      

    <table border="1" cellspacing="0" cellpadding="0" width="100%">
                <tr>
                        <td class="gname" width="60%">测试1</td>
                        <td  width="60%">xiao1</td>
                        <td width="60%">xiao2</td>
                </tr>
    </table>
    

      

  • 相关阅读:
    LeetCode
    LeetCode
    LeetCode
    LeetCode
    LeetCode
    LeetCode
    LeetCode
    LeetCode
    LeetCode
    LeetCode
  • 原文地址:https://www.cnblogs.com/genghuilove/p/7484866.html
Copyright © 2011-2022 走看看