title: removing a row in success funciton of ajax call
body: <p>I want to remove a table's row with jquery. When i write this jQuery(this).parent().parent().fadeOut(); statement outside ajax success function it fades out row. but it does not work if written within ajax success function.</p>
  
  <pre><code>jQuery(document).ready(function() {
          jQuery('.assignme').click(function(){
              id = jQuery(this).attr('rel');
              jQuery.ajax({
                  url:'home.php?ajax=1&amp;action=assing_to_agent&amp;application_id='+id,
                  success:function(data){
                      if(data==-1)
                          alert('Assigned to someone else');
                      jQuery(this).parent().parent().fadeOut();   
                  }
              });
  
              return false;
          });
      });
  </code></pre>
  
  <p>Here is html</p>
  
  <pre><code> &lt;tr&gt;
      &lt;td&gt;&lt;button class="assignme" rel="&lt;?php echo $row_rs_report['application_id']; ?&gt;"&gt;Assign Me&lt;/button&gt;&lt;/td&gt;&lt;/tr&gt;
  </code></pre>
  
  <p>Also if someone can tell me about a good practice to send a value to ajax method as i m sending id using rel attribute?</p>