Redirect_to is not working with ajax forms


#1

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


#2

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