title: Only select one row at a time using jquery
body: <p>I am using <code>mouseover()</code>, <code>mouseout()</code> and <code>click()</code> to highlight rows on mouseover and add a highlight class on click:</p>
  
  <pre><code>    //Mouseover any row by adding class=mouseRow
      $(".mouseRow tr").mouseover(function() {
          $(this).addClass("ui-state-active");
      });
      $(".mouseRow tr").mouseout(function() {
          $(this).removeClass("ui-state-active");
      });
      $('.mouseRow tr').click(function(event) {
          $(this).toggleClass('selectRow'); 
      });
  </code></pre>
  
  <p>The above code will allow a user to 'highlight' (i.e add class <code>selectRow</code>) to as many rows as they want. What is the best way, using jQuery, to limit the number of rows they can select to just one (so that if they click one row, then click another it will remove the '<code>selectRow</code>' class from the previously selected row)?</p>