I''d like to have an action in one controller, render the view from another controller. The code that I know is wrong but would like to use is: render :controller => "x" :action => "y" I could simply copy controller X''s view to the current controller, but I''m trying to minimize duplicated code. Any ideas? --~--~---------~--~----~------------~-------~--~----~ 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?hl=en -~----------~----~----~----~------~----~------~--~---
i think you can just give the path to the render like render "controllera/filename" Joe Cairns wrote:> I''d like to have an action in one controller, render the view from > another > controller. The code that I know is wrong but would like to use is: > render :controller => "x" :action => "y" > > I could simply copy controller X''s view to the current controller, but > I''m > trying to minimize duplicated code. Any ideas?-- 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?hl=en -~----------~----~----~----~------~----~------~--~---