This is silly, but I just can\'t figure out how to style the input element created by Rails button_to
-- and yes, I\'ve read the docs over and over again and tr
The signature of the method button_to is
button_to(name = nil, options = nil, html_options = nil, &block)
So use {}
to distinguish options
and html_options
<%= button_to "Claim", {action: "claim", idea_id: idea.id, remote: true}, {class: 'btn btn-small'} %>
<%= button_to "Claim", {action: "claim", idea_id: idea.id, remote: true}, {form_class: 'form', class: 'btn btn-small'} %>
form_class: class for the form
class : class for button in the form