Ruby on Rails Sunday, August 1, 2010

>
> That's why your redirect doesn't work - the redirect just redirects
> the request made by the JavaScript (rjs has a page.redirect_to thing
> that will produce the JavaScript required to point the browser window
> at a new location. If you are going to do a full page refresh though,
> what's the point of using Ajax?)
>
> Fred

I didn't really want the whole page refresh I was only using it coz the
rjs wasn't working. I want the .rjs coz I want comments to go straight
up with no refresh.

Are you saying I should make a line

page.redirect_to story_path(@story), :controller => 'stories'

in the .rjs?
--
Posted via http://www.ruby-forum.com/.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

No comments:

Post a Comment