title: How to select just a row of table using jQuery
body: <p>I have created a table on my application same following code </p>
  
  <pre><code>&lt;table class="spreadsheet"&gt;
  &lt;tr&gt;
  &lt;td&gt;1&lt;/td&gt;
  &lt;td&gt;2&lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr&gt;
  &lt;td&gt;3&lt;/td&gt;
  &lt;td&gt;4&lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr&gt;
  &lt;td&gt;5&lt;/td&gt;
  &lt;td&gt;6&lt;/td&gt;
  &lt;/tr&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>I select a row by click with following jQuery code </p>
  
  <pre><code> $("tr").click(function(){
   $(this).toggleClass("otherstyle");
  }
  </code></pre>
  
  <p>and my css is </p>
  
  <pre><code>tr.otherstyle td
  {
      background-color: #d1db3e;
      color:#000;
  }
  </code></pre>
  
  <p>I would like when I click on a row, other rows be <strong>unselected</strong>,
  and just one row be selected.</p>
  
  <p>How we could create this?</p>