Forum: Ruby on Rails redirect_to is not working with ajax forms

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Joshua B. (Guest)
on 2006-01-17 02:27
(Received via mailing list)
I'm having trouble using redirect_to in an action called by a
remote_form_tag.
The log shows the redirect, and rendering of the redirected page, but
the
browser
won't redirect. If I set :update in the form_remote_tag, the page that
was
supposed
to be redirected to will replace the :update elements content, and crash
FF1.5

Running edge rails, and utf8 encoding

joshua
Nick S. (Guest)
on 2006-01-17 15:57
(Received via mailing list)
Redirects aren't going to work with the straight ajax calls. You'll
either
need to create some custom javascript redirect based on the return
value, or
you could use the new RJS templates which have this functionality built
in
for you. Plus, I've found the RJS stuff to be a lot easier/neater to
deal
with and am enjoying them very much. Search the wiki for finding info
about
the plugin for RJS or you can run edge rails which has them in it.

-Nick
This topic is locked and can not be replied to.