rails.nerd-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
2010-Jul-26 12:32 UTC
loading a partial via AJAX
Hi I accept that partials are not intended to be exposed via a URL However I''d like to load my basic _form.html.erb partial for my model to build basic AJAX form So one way to do this is to put something like this in the controller: def basic_form render :partial=>"form" end ...... but...... is there a cleaner way? cheers -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
rails.nerd-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
2010-Jul-26 22:38 UTC
Re: loading a partial via AJAX
Any ideas folks? On Jul 26, 10:32 pm, "rails.n...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org" <rails.n...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi > > I accept that partials are not intended to be exposed via a URL > > However I''d like to load my basic _form.html.erb partial for my model > to build basic AJAX form > > So one way to do this is to put something like this in the controller: > > def basic_form > render :partial=>"form" > end > > ...... but...... is there a cleaner way? > > cheers-- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org 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.