Ajax Problem

Hi,

I'm using Jquery on jrails. I used ajax to submit for one textbox. I
want to put an image when ajax is calling. But i'm getting problem here.
Please solve my problem.Here is the part of code

<label>Prouct Category</label><br/>
<%#= collection_select("product", "type_1" , product_types,
"product_type","product_type") %>
<%= collection_select("product", "type_1" ,
@product_types,"product_type","product_type") %>
<%= text_field "products", "product_type", :size=>25 %>
<%= submit_to_remote 'product_type','OK', :class=>'image', :url => {
:controller => 'inquiries', :action => 'add_product',:id =>
id},:complete => "$('loading_latest').hide();", :loading =>
"$('loading_latest').show();" %>
  <img src="/images/ajax-loading.gif" style="display:none;"
id="loading_latest"/>

Thanks,
  Manjula