I''m using form_remote_tag like this: <%= form_remote_tag \ :update => "div_id_dataentry_bottom_ajax", :loading => "document.getElementById(''wait'').innerHTML=''Loading...'';", :url => { :action => "dataentry_bottom_edit" } %> And it makes this code: <form action="/x/dataentry_bottom_edit" method="post" onsubmit="new Ajax.Updater(''div_id_dataentry_bottom_ajax'', ''/x/dataentry_bottom_edit'', {asynchronous:true, evalScripts:true, onLoading:function(request){document.getElementById(''div_id_dataentry_bottom_ajax'').innerHTML=''Loading...'';}, parameters:Form.serialize(this)}); return false;"> How do i get it to set the name tag, so i can do some javascript??? Like this: <form name="xxx" ... Cheers, you guys are awesome. -- Posted via http://www.ruby-forum.com/.
I believe you want: form_remote_tag :html => {:name => ''my_name''}, :update => ... Bob Silva http://www.railtie.net/ On Wednesday, March 15, 2006, at 3:32 AM, chris hulbert wrote:>I''m using form_remote_tag like this: > ><%= form_remote_tag \ > :update => "div_id_dataentry_bottom_ajax", > :loading => "document.getElementById(''wait'').innerHTML=''Loading...'';", > :url => { :action => "dataentry_bottom_edit" } %> > >And it makes this code: > ><form action="/x/dataentry_bottom_edit" method="post" onsubmit="new >Ajax.Updater(''div_id_dataentry_bottom_ajax'', ''/x/dataentry_bottom_edit'', >{asynchronous:true, evalScripts:true, >onLoading:function(request){document.getElementById(''div_id_dataentry >_bottom_ajax'').innerHTML=''Loading...'';}, >parameters:Form.serialize(this)}); return false;"> > >How do i get it to set the name tag, so i can do some javascript??? >Like this: ><form name="xxx" ... > >Cheers, you guys are awesome. > >-- >Posted via http://www.ruby-forum.com/. >_______________________________________________ >Rails mailing list >Rails@lists.rubyonrails.org >http://lists.rubyonrails.org/mailman/listinfo/rails-- Posted with http://DevLists.com. Sign up and save your time!
chris hulbert
2006-Mar-15 03:51 UTC
[Rails] Re: Using form_remote_tag, setting the form name
Bob Silva wrote:> I believe you want: > > form_remote_tag :html => {:name => ''my_name''}, :update => ... > > Bob Silva > http://www.railtie.net/I worship at your feet... -- Posted via http://www.ruby-forum.com/.