Re: [Rails] How do I prevent rails from redirecting to request referrer after create

2020-01-29 Thread fugee ohu
On Monday, January 27, 2020 at 10:52:28 PM UTC-5, Walter Lee Davis wrote: > > You can define (in your controller) what the create action is after a > successful save, and if you only want to do that for one format, and not > the others, you can use the usual method for doing that in a controlle

Re: [Rails] How do I prevent rails from redirecting to request referrer after create

2020-01-27 Thread fugee ohu
On Monday, January 27, 2020 at 10:52:28 PM UTC-5, Walter Lee Davis wrote: > > You can define (in your controller) what the create action is after a > successful save, and if you only want to do that for one format, and not > the others, you can use the usual method for doing that in a controlle

Re: [Rails] How do I prevent rails from redirecting to request referrer after create

2020-01-27 Thread Walter Lee Davis
You can define (in your controller) what the create action is after a successful save, and if you only want to do that for one format, and not the others, you can use the usual method for doing that in a controller, with: if @foo.create(foo_params) respond_to do |format| if format.js

[Rails] How do I prevent rails from redirecting to request referrer after create

2020-01-27 Thread fugee ohu
I'm broadcasting to a javascript channel in my create action instead of redirecting but rails redirects to request referrer -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it,