I''m trying to do this latest project using Restful techniques, but how do you deal with Ajax and http POSTs? I have a helper function that generates a paginated, searchable custom ajax grid (developed pre-rest). The form_remote_tag really, really wants to use post. The observe_field wants to post. I had eventually wanted to use an autocomplete, but that uses post as well. A post to the "list" url attempts to create a new resource. How do you all deal with this? - Create a ;search/filter type action for the postbacks? - Somehow get all these events to use GET? - Inspect the post and determine best course of action (feels like a total hack) I''ve been muckin'' around with this but the answer has not jumped out at me yet. Thanks in advance.... --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
On Feb 15, 8:50 am, "Meech" <Meech...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> I''m trying to do this latest project using Restful techniques, but how > do you deal with Ajax and http POSTs?> - Somehow get all these events to use GET?yes, add a :method => :get in the link_to_remote --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
but... <%= form_remote_tag :method=>:get %> still renders as: <form method="post" If the user clicks on the submit buttin -- it''s indeed posted. On Feb 15, 11:54 am, "takeo" <t...-HPMkS9pGfdgAvxtiuMwx3w@public.gmane.org> wrote:> On Feb 15, 8:50 am, "Meech" <Meech...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > I''m trying to do this latest project using Restful techniques, but how > > do you deal with Ajax and http POSTs? > > - Somehow get all these events to use GET? > > yes, add a :method => :get in the link_to_remote--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---