Topic: AJAX: change color of the button, that was clicked

Hey there

i have a view that has several buttons that trigger an action via AJAX:

<% @participants.each do |participant| %>
  <tr>
    <td><%= button_to 'My AJAX Button', { :action => 'perform_checkin', :id => participant.id }, :remote => true %></td>
  </tr>
<% end %>

Now i want to change the color of the button that was clicked, when the AJAX action succeeds. I've been using google for about 3h now and couldn't find any hints. Could someone please help me?

Re: AJAX: change color of the button, that was clicked

You can use one of  jQuery  event handler functions described here: http://api.jquery.com/click/