rubynewbie
2006-Feb-23 21:21 UTC
[Rails] form_remote_tag params not passed .. PLEASE help!
This problem is driving me nuts Here is my code for the view: <div class="signW"> <div class="sign"> coming soon! <br/> <div class="stxt"> Email address: </div> <div id="result"> </div> <%= form_remote_tag(:update => ''result'', :url => { :controller => ''launch'', :action => ''process_email'' }, :with => "''blah='' + escape(value)", :complete => "Element.hide(''eid'');Element.hide(''sub'');Element.show(''result'')", :position => "top") %> <input type="text" id="eid" name="blah" value="" /> <input type="submit" id="sub" name="commit" value="Sign Up"/> <%= end_form_tag %> Here is my controller code: class LaunchController < ApplicationController layout "launch-layout" def index end def process_email render_text @params.inspect end end It only prints out {"action"=>"process_email", "controller"=>"launch"} The parameters DONT SHOW UP!!! I have <%= javascript_include_tag "prototype" %> in my layout. where am I screwing up???? PLEASE HELP! -- Posted via http://www.ruby-forum.com/.
rubynewbie
2006-Feb-23 21:28 UTC
[Rails] Re: form_remote_tag params not passed .. PLEASE help!
what is even more scary is the production.log generates the following Processing LaunchController#process_email (for x.u.x.h at 2006-02-23 16:26:50) [GET] Parameters: {"action"=>"process_email", "controller"=>"launch"} Response body was encoded with gzip Completed in 0.00327 (305 reqs/sec) | 200 OK Doesnt show the parameters! is something wrong with my view code?? -- Posted via http://www.ruby-forum.com/.
Mark Reginald James
2006-Feb-23 22:17 UTC
[Rails] Re: form_remote_tag params not passed .. PLEASE help!
rubynewbie wrote:> <%= form_remote_tag(:update => ''result'', > :url => { :controller => ''launch'', :action => > ''process_email'' }, > :with => "''blah='' + escape(value)", > :complete => > "Element.hide(''eid'');Element.hide(''sub'');Element.show(''result'')", > :position => "top") %> > <input type="text" id="eid" name="blah" value="" /> > <input type="submit" id="sub" name="commit" value="Sign Up"/> > <%= end_form_tag %> > ====> It only prints out {"action"=>"process_email", "controller"=>"launch"} > > The parameters DONT SHOW UP!!!You probably want :with => "''blah='' + escape($F(''blah''))", or remove the :with option and escape at the server. -- We develop, watch us RoR, in numbers too big to ignore.
rubynewbie
2006-Feb-23 23:24 UTC
[Rails] Re: form_remote_tag params not passed .. PLEASE help!
Mark Reginald James wrote:> rubynewbie wrote: > >> ====>> It only prints out {"action"=>"process_email", "controller"=>"launch"} >> >> The parameters DONT SHOW UP!!! > > You probably want > > :with => "''blah='' + escape($F(''blah''))", > > or remove the :with option and escape at the server. > > -- > We develop, watch us RoR, in numbers too big to ignore.:with was added to see if the parameter would be passed .. The problem is this requested should be generating a POST on the server its generating a GET! Weird! -- Posted via http://www.ruby-forum.com/.
Mark Reginald James
2006-Feb-23 23:40 UTC
[Rails] Re: form_remote_tag params not passed .. PLEASE help!
rubynewbie wrote:> :with was added to see if the parameter would be passed .. The problem > is this requested should be generating a POST on the server its > generating a GET! Weird!Ah, OK. Look at the source of the generated HTML to make sure prototype is being included. -- We develop, watch us RoR, in numbers too big to ignore.
Possibly Parallel Threads
- Nested serialization with to_json and to_xml with array and hash element
- Help needed with ActiveRecord
- Deleting rows dataframe in R conditional to “if any of (a specific variable) is equal to”
- [BUG] imap-login segfault when running nmap -sV
- Combining some duplicated rows & summing one of their column