jquery 给a标签绑定click

一.

<div id="main">
<div class="tab-content">
 <div class="container" >
     <div class="row">
         <div class="col-lg-6 col-sm-12 col-md-6">
         <table class="table table-responsive table-hover">
              
              <tbody>
              <caption class="text-primary" >网络书籍</caption>
              <tr  th:each="book : ${resourcesList}">
                  <td th:text="${book.key}"> </td>
                  <td th:text="${book.value}"> </td>
                  <td><a class="a_click" >下载</a></td>
              </tr>
              </tbody>
        </table>
    </div >
         <div class="col-lg-6 col-sm-12 col-md-6" ></div>
     </div>
 </div> 
</div>
</div>
 <script>

 $(document).ready(function() {
     $("a[class='a_click']").click(function(){

     });
 });
</script>

方法二:

posted @ 2019-07-04 17:49  江期玉  阅读(8151)  评论(0编辑  收藏  举报