Deleting <div> rows Using JQuery and adding loading.gif

Deleting <div> rows Using JQuery and adding loading.gif


Hi guys,... can anyone help me please,... 
How can I add class loading.gif
I'm not to good with jquery,... but delete php function is working 

I have a <div> with id="photo_<?php echo $photo['Photo']['id'] ?>"  

 <div id="photo_<?php echo $photo['Photo']['id'] ?>"> 

// I need to add class loading.gif into this div

          -----  here is my photo with link to delete ----- 

   and here is the link to delete: with  'id' => 'photo_delete_' . $photo['Photo']['id']

 <?php echo $html->link(__('delete', true), 'javascript:void(0)', array('title' => ucfirst(__('delete', true)),  'id' => 'photo_delete_' . $photo['Photo']['id'])) ?>


 </div>

 here is the jquery script, ... 

<script>     
$(document).ready(function(){
$('#photo_<?php echo $photo['Photo']['id'] ?> a.photo_delete_<?php echo $photo['Photo']['id'] ?>').live("click",function() {

if (confirm("Are you sure you want to delete this photo?")){
var id = $(this).attr("id")
var data = 'id=' + id ;
var parent = $(this).parent().parent().parent();
  parent.fadeOut('slow');       
          
$.ajax({
type: "POST",
url: "<?php echo $html->url("/photos/ajax_delete/" . $photo["Photo"]["id"]) ?>",
  data: data,                    
cache: false,     
               
success: function(){                     
parent.fadeOut('slow', function() {$(this).remove();});
//// this will remove the row
}
});
}
});
}); 
</script>

and it's got a demo for removing table rows,... but not anything in regards to loading.gif

How do I do this ??? 

thanks in advance 
chris