title: jQuery Slide Up Table Row
body: <p>I am building a custom jQuery plugin which allows the user to delete records within a table in real-time, among many other things. When the records are deleted, I would like the the background-color of the deleted table row to turn red, then slide up out of view.</p>
  
  <p>Here is a snippet of my code below, which doesn't do any of the color changing animation, nor does it slide up the row. However, it does delete the row when what is supposed to be the slide up animation, finishes. Some things to know when reviewing the code below:</p>
  
  <ol>
  <li>The "object" variable is a jQuery reference to the object which was clicked and triggered the delete operation.</li>
  <li>The "object.parent().parent()" object is the row which is being deleted.</li>
  <li>The "deleteHighlight" CSS class contains the color which will turn the row a red color.</li>
  <li>The "addClass" method uses jQueryUI's "addClass" method, not jQuery's. It allows an animated effect and a callback.</li>
  </ol>
  
  <hr>
  
  <pre><code>object.parent().parent().addClass('deleteHighlight', 1000, function() {
  //Fold the table row
    $(this).slideUp(1000, function() {
    //Delete the old row
      $(this).remove();
    });
  });
  </code></pre>
  
  <p>Here is the HTML on which this is being executed, nothing special:</p>
  
  <pre><code>&lt;table class="dataTable"&gt;
  &lt;thead&gt;
  &lt;tr&gt;
  &lt;th&gt;&amp;nbsp;&lt;/th&gt;
  &lt;th&gt;Title&lt;/th&gt;
  &lt;th&gt;Content Snapshot&lt;/th&gt;
  &lt;th&gt;Management&lt;/th&gt;
  &lt;/tr&gt;
  &lt;/thead&gt;
  
  &lt;tbody&gt;
  &lt;tr class="odd" id="11" name="1"&gt;
  &lt;td class="center width50"&gt;&lt;a class="dragger"&gt;&lt;/a&gt;&lt;a class="visibilityTrigger eyeShow"&gt;&lt;/a&gt;&lt;/td&gt;
  &lt;td class="center width150"&gt;Title&lt;/td&gt;
  &lt;td&gt;
  &lt;div class="clipContainer"&gt;Content&lt;/div&gt;
  &lt;div class="hide contentContainer"&gt;Content&lt;/div&gt;
  &lt;div class="hide URLContainer"&gt;my-url&lt;/div&gt;
  &lt;/td&gt;
  &lt;td class="center width75"&gt;&lt;a class="edit"&gt;&lt;/a&gt;&lt;a class="delete"&gt;&lt;/a&gt;&lt;/td&gt;
  &lt;/tr&gt;
  &lt;/tbody&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>Could someone please provide an example of how I can fix this?</p>
  
  <p>Thank you for your time.</p>