FDI
1
Hello,
I want to change the URL of the page when a certain condition is met after form submission.
Imagine I have the following action in Rails controller
if condition == true
redirect_to destination_path
else
respond_to do |format|
format.html { render partial: 'question', locals: { q: @question } }
end
end
so if the redirect_to get executed I want to change the URL, otherwise the URL will stay the same
how can I do that?
the issue you’re describing has a solution here
FDI
3
Thank you for your help, the solution worked
1 Like