allow me to point out that you should be using button_to for the
Perhaps someone could correct that in the docs?
I think it’s a semantic distinction. Like the hallowed CUA used to say
“a dialog box is for brief interaction, such as presenting one
question to the user”. Then we’d use one to occupy the “form” concept,
and some dipshit consultant would catch us and ask us if we read the
CUA. When we gave it to him with shrink-wrap on it, my colleague said,
“Well, we read it, but then we put the shrinkwrap back on it.”
Where was I? Oh, yeah - destructive actions should - semantically - be
behind buttons and POSTs, not A HREFs and GETs.
We’re also assuming that the table names correspond to model names,
which is a pretty big assumption. Just like in ActiveRecord, you’d
still be able to manually specify an :action, but this seems like a
textbook case where Rails can again leverage intelligent defaults.
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.