title: Toggle hide/show <tr> using jQuery
body: <p>I have this code to show <code>&lt;tr&gt;</code> in my table but with every click, it hides the textbox that must be shown when the button is clicked.</p>
  
  <p>Below is my <code>jQuery</code> code to show the textbox:</p>
  
  <pre><code>$(function() {
     $('#btnAdd').click(function() {
         $('.td1').show();
     });
  });
  </code></pre>
  
  <p>And this is my code in <code>&lt;table&gt;</code>:</p>
  
  <pre><code>&lt;button id="btnAdd" name="btnAdd" onclick="toggle();" class="span1"&gt;ADD&lt;/button&gt;
  &lt;tr class="td1" id="td1" style=""&gt;  
       &lt;td&gt;&lt;input type="text" name="val1" id="val1"/&gt;&lt;/td&gt;
       &lt;td&gt;&lt;input type="text" name="val2" id="val2"/&gt;&lt;/td&gt;
  &lt;/tr&gt;
  </code></pre>