I am trying to submit a form, but if I just put form_for @classroom I get a \"No route matches [POST]\" error.
form_for @classroom
Now with the code posted below, I get th
form_for takes an object as first argument, and its usually better to keep the REST-like way of rails handling the update method.
form_for
update
The action of you html form displays "/classrooms/23/edit" so yes it won't work.
action
form_for(@classroom, url: update_classroom_path(@classroom), method: "patch")