PUT recognized as GET

I am getting mad. Here are two requests which should be PUT, but one is
and not the other. I do not understand why. They come from two different
forms.

Processing NodesController#show (for …) [GET]
Session ID: …
Parameters: {“node”=>{…}, “_method”=>“put”, “action”=>“show”,
“id”=>“251”, “controller”=>“nodes”}

Processing NodesController#update (for …) [PUT]
Session ID: …
Parameters: {“node”=>{…}, “edit”=>“popup”, “_method”=>“put”,
“action”=>“update”, “id”=>“251”, “controller”=>“nodes”}

Any clue before I jump into the raw_data ?

Are you on edge rails, by any chance? I’m seeing some weirdness
introduced in the past couple of days, where ajax requests don’t seem
to be having their method received correctly…

Gaspard B. wrote:

I am getting mad. Here are two requests which should be PUT, but one is
and not the other. I do not understand why. They come from two different
forms.

Processing NodesController#show (for …) [GET]
Session ID: …
Parameters: {“node”=>{…}, “_method”=>“put”, “action”=>“show”,
“id”=>“251”, “controller”=>“nodes”}

Processing NodesController#update (for …) [PUT]
Session ID: …
Parameters: {“node”=>{…}, “edit”=>“popup”, “_method”=>“put”,
“action”=>“update”, “id”=>“251”, “controller”=>“nodes”}

Any clue before I jump into the raw_data ?

After searching in the raw_data of the mongrel instance, I read
“REQUEST_METHOD”=>“GET”, and nasty me I saw that my form was :

instead of .

Sorry for the trouble.

Gaspard

Jonathan del Strother wrote:

Are you on edge rails, by any chance? I’m seeing some weirdness
introduced in the past couple of days, where ajax requests don’t seem
to be having their method received correctly…

My error was related to a form tag missing the method=‘post’ attribute.
I am doing a LOT of cleanup and froze rails to rev. 6633 so I can track
my own bugs. I will catchup when my own code is stable.

You can look at the commit feed
feed://dev.rubyonrails.org/timeline?changeset=on&max=50&daysback=90&format=rss
to see if anything changed related to your bugs…

Gaspard


zena, the peaceful cms
http://zenadmin.org

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs