I'm trying to apply a class to the form generated by button_to in Rails 3.
The :class
option sets the class for the submit button so the docs tell us to use :form_class
to apply a class to the form.
E.g.
<%= button_to 'x', user_contact_path(@user, contact), :method => :delete, :form_class => "delete" %>
This just adds the attribute form_class="delete"
to the button element. I've tried various combinations using :html_options
and so on.
Anybody know how to do this?