Phongphat Kangkong
2007-Feb-06 08:17 UTC
Render component from other rails app in current rails app..
Can I render component from other rails app in current rails app? example:: app A want to render component from app B. ps.I''m weak in english. - -" -- 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 -~----------~----~----~----~------~----~------~--~---
張衡華
2007-Feb-12 03:14 UTC
Re: Render component from other rails app in current rails app..
You can try this helper; (put in application_helper.rb, use by view) it make an ajax call from given url. def render_remote(url, view = ''remote'') options = {} options[:update] = view options[:url] = url options[:method] = :get render :inline => %{<span id="#{view}"><p>Loading...</p><script type="text/javascript" language="JavaScript">#{remote_function(options)}</script></span>} end Regards, herngwah On Feb 6, 4:17 pm, Phongphat Kangkong <rails-mailing-l...@andreas- s.net> wrote:> Can I rendercomponentfrom other rails app in current rails app? > example:: > app A want to rendercomponentfrom app B. > > ps.I''m weak in english. - -" > > -- > Posted viahttp://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 -~----------~----~----~----~------~----~------~--~---