Having a data-confirm tag in a link in Rails 3 generates the unobstructive Javascript needed to have an alert for confirmation. For example:
<%= link_to "Destroy", @product, :confirm => "Are you sure?", :method => :delete %>
However, I would like to change this behaviour to the following:
Clicking a button changes its text to 'Sure?' and then the user has to click it again for the action to take place. (perhaps the text can even go back to normal after a timeout)
Where is the best place to change this behaviour in a Rails 3.1 application? (BTW, I'm using Twitter Bootstrap in case there is a better solution that can work nicely this that).