提交 2ac48390 编写于 作者: M Marcel Molina

Update respond_to docs to follow established naming convention

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4759 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
上级 d7f780e0
......@@ -17,9 +17,9 @@ module InstanceMethods
# def list
# @people = Person.find(:all)
#
# respond_to do |wants|
# wants.html
# wants.xml { render :xml => @people.to_xml }
# respond_to do |format|
# format.html
# format.xml { render :xml => @people.to_xml }
# end
# end
#
......@@ -44,10 +44,10 @@ module InstanceMethods
# @company = Company.find_or_create_by_name(company[:name])
# @person = @company.people.create(params[:person])
#
# respond_to do |wants|
# wants.html { redirect_to(person_list_url) }
# wants.js
# wants.xml { render :xml => @person.to_xml(:include => @company) }
# respond_to do |format|
# format.html { redirect_to(person_list_url) }
# format.js
# format.xml { render :xml => @person.to_xml(:include => @company) }
# end
# end
#
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册