<%= form_remote_tag :url => {:action => 'comment', :id => @article}, :update => 'comments_div', :loading => 'commentLoading()', :complete => 'commentComplete()', :html => {:id => 'commentform', :class => 'comments' } %>
Comments

<%= submit_to_remote('preview', 'Preview!', :update => 'preview', :complete => "Element.show('preview')", :url => { :action => 'comment_preview' }) %> <%= submit_tag 'Submit', :onclick => "$('commentform').onsubmit();this.disabled=true;Element.hide('preview');return false;" %> <%= image_tag '/images/theme/spinner.gif', :id => 'spinner', :style => 'display:none' %>

<%= end_form_tag %>