AJAX提供的Rails资源

In rails, what kind of AJAX call would need to be made in order to create and modify resources. Say if i had a resource like this

Man(age: integer, country_from:string, residence:string)

Now how would this be made through an AJAX call (like sending post to my create function, how would parameters be sent in, how would my controllers be setup). Be detailed, my AJAX is very, very, very weak. (right now i have my Man made like rails generate scaffold Man age:int country_from:string ...)

PS

Im using rails 3

查看全部
weixin_33738982
?Briella
2011/11/30 14:27
  • controller
  • ruby-on-rails
  • ajax
  • 点赞
  • 收藏
  • 回答
    私信

2个回复