[Rails] Re: submite_to_remote not works for me

2009-08-06 Thread bill walton

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

 p
 label
 Title
 /label
 %= f.text_field :title,:class=validate[required,length
 [5,8]] text-input %
 /p
 p
 label
 Description
 /label
 %= f.text_area :description,:rows=4 %
 /p
 p
 label
 Assign to
 /label
 %= select(todo,user_id,@users.map {|u|
 [u.login,u.id]  }) %
 /p
 %=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.
 
 
 
 
 
 
 
 
 
  


--~--~-~--~~~---~--~~
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@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~--~~~~--~~--~--~---



[Rails] Re: submite_to_remote not works for me

2009-08-06 Thread nirosh

thx to the reply that works for me

nirosh
--~--~-~--~~~---~--~~
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@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~--~~~~--~~--~--~---