Hi - what I basically have is have a webpage where you have a picture. If you click on the comment button, a comment section will open up on the same page if you are logged in. If you are not logged in, a login section will open up on the same page saying to login. Once the user logs in my webpage should redirect back to the comments section on the same page with the picture. Instead it''s redirecting to a new page, showing only the comments and not the picture. These are the steps my code makes when accesing my webpage: 1) it render the pictuer page ''lookat/pictures'' 2) when you click on the comment button the controll checks if you are logged in. if you are not it save the last url into a cookie ''cookies[:return_to] = {:value => @request.request_uri, :expires => nil }'', which was ''your/comments'' 3) once you log in it checks to see if there is a url in the cookies and then does a ''redirect_to_url'', the current url is ''your/comments'' which gets render and doesn''t show the picture. Is there any way to do a redierct back to the picture page with the comment section showing? If you need code example let me know and I''ll post it. Thanks in advance. -- 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---