title: How to apply css to table rows
body: <p>I need to apply background color to the alternating rows of my html table.</p>
  
  <p>My current code:</p>
  
  <pre><code>.licList
      {
          width: 100%;
          border: 1px solid #f7f7f7;
          text-align: center;
          border-collapse: collapse;
      }
  
      .licList th
      {
          font-weight: bold;
          background-color: #dbdbdb;
          border-bottom: 1px solid #f1f1f1;
          padding: 4px 5px;
      }
  
      .licList td
      {
          padding: 4px 5px;
      }
  
      .odd
      {
          background-color: #ffffff;
      }
      .odd td
      {
          border-bottom: 1px solid #cef;
      }
  </code></pre>
  
  <p>and jquery is</p>
  
  <pre><code>    $(document).ready(function () {
          $("licList:tr:odd").addClass("odd");
      });
  </code></pre>
  
  <p>I'm sure that the above jquery is not correct I've multiple tables in single page so I can't apply</p>
  
  <pre><code>$(document).ready(function(){
      $("tr:odd").addClass("odd");
  });
  </code></pre>
  
  <p>so my question is how to solve this problem????</p>