Submite_to_remote not works for me

<% form_for :todo,:url =>todos_path,:html=>{:name=>“new_todo”} do |f|
%>



Title

<%= f.text_field :title,:class=>“validate[required,length
[5,8]] text-input” %>




Description

<%= f.text_area :description,:rows=>“4” %>




Assign to

<%= select(“todo”,“user_id”,@users.map {|u|
[u.login,u.id] }) %>


<%=f.hidden_field :assigned_by,:value=>current_user.id
%>
<%= submit_to_remote ‘create_btn’, ‘Create’, :url => { :action =>
‘new’ } %>
<% end %>

any suggestions about this code
please let me know what is the error of this code.

Hi Nirosh,

On Thu, 2009-08-06 at 11:46 -0700, nirosh wrote:

<% form_for :todo,:url =>todos_path,:html=>{:name=>“new_todo”} do |f|
%>

You need to use form_remote_for(…

HTH,
Bill

thx to the reply that works for me

nirosh

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs