Using redirect_to to: create an action

I am trying to redirect the create method of another controller. However, I cannot find a way to set the POST method. This leads to an index method call. Usage :method => :post simply creates a new parameter, but does not change the http method.

Any ideas on how to redirect the create method?

+4
source share
1 answer

You cannot post redirect messages. This is part of the HTTP specification - redirecting calls an HTTP header.

+7
source

Source: https://habr.com/ru/post/1303870/


All Articles