Hi everybody, I''m trying to change my current forms in my app to remote_forms. It was my understanding that remote_form_for and form_for work in the same way, so I just wanted to change the methods. My code looks like: <% form_remote_for :post, :url => posts_url do |f| %> <%= render :partial => ''form_posts'', :locals => {:f => f} %> <%= table_submit_tag "Chercher" %> <% end %> The problem of this code is that it generates an empty form: <form id="foo" onsubmit="new Ajax.Request(''http://localhost:3000/posts/'', {asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;" method="post" action="http://localhost:3000/posts/"/> params[:post] is empty (Form.serialize(this) serializes an emtpy form...). Anyone has an idea what I am missing? I thought it was because the partial wasn''t passed to the block, but I have the same proble when I past it. Moreover @post does exist and I have the same problem without using block, but using form_remote_tag. The partial is dummy: f.text_field :body Thanks, -- ,========================. | Pierre-Alexandre Meyer | | email : pam-1sEOgp2Wo8Qdnm+yROfE0A@public.gmane.org | `========================'' --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
what version of rails? There where some problems with this that helper method in 1.1.6. However, it should work as is in 1.2.x -- 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 -~----------~----~----~----~------~----~------~--~---
On Mon, Jun 04, 2007 at 07:30:11AM +0200, Keynan Pratt wrote :> what version of rails? > There where some problems with this that helper method in 1.1.6. > However, it should work as is in 1.2.xRails 1.2.3 That''s really weird... -- ,========================. | Pierre-Alexandre Meyer | | email : pam-1sEOgp2Wo8Qdnm+yROfE0A@public.gmane.org | `========================'' --~--~---------~--~----~------------~-------~--~----~ 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 Mon, Jun 04, 2007 at 09:05:43AM +0200, Pierre-Alexandre Meyer wrote :> That''s really weird...Extracted from http://www.cs.tut.fi/~jkorpela/forms/tables.html#example: Tables and forms can be nested either way. But if you put forms into tables, each form must be completely included into a single table cell (one TD element in practice). Thereby the forms are each completely independent. See my document on choices in HTML forms for some simple examples. It was an HTML problem. Sorry. -- ,========================. | Pierre-Alexandre Meyer | | email : pam-1sEOgp2Wo8Qdnm+yROfE0A@public.gmane.org | `========================'' --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---