aboutsummaryrefslogtreecommitdiffstats
path: root/railties/guides/source/action_mailer_basics.textile
diff options
context:
space:
mode:
authorPrem Sichanugrist <s@sikachu.com>2011-04-26 22:23:57 +0700
committerPrem Sichanugrist <s@sikachu.com>2011-04-26 22:23:57 +0700
commite6898e3b609ed411692206c4ae9516f9ca4f9cf3 (patch)
treebd058914142d0ba1cdfd44aff9423c2c7a945508 /railties/guides/source/action_mailer_basics.textile
parentc60e207674fb7844c9586f98be6ad930362b1a3d (diff)
downloadrails-e6898e3b609ed411692206c4ae9516f9ca4f9cf3.tar.gz
rails-e6898e3b609ed411692206c4ae9516f9ca4f9cf3.tar.bz2
rails-e6898e3b609ed411692206c4ae9516f9ca4f9cf3.zip
Change examples in guide to reflect changes from XML -> JSON
Diffstat (limited to 'railties/guides/source/action_mailer_basics.textile')
-rw-r--r--railties/guides/source/action_mailer_basics.textile6
1 files changed, 3 insertions, 3 deletions
diff --git a/railties/guides/source/action_mailer_basics.textile b/railties/guides/source/action_mailer_basics.textile
index 56da360972..a6ff8f877d 100644
--- a/railties/guides/source/action_mailer_basics.textile
+++ b/railties/guides/source/action_mailer_basics.textile
@@ -120,7 +120,7 @@ Now that we have a user model to play with, we will just edit the +app/controlle
<ruby>
class UsersController < ApplicationController
# POST /users
- # POST /users.xml
+ # POST /users.json
def create
@user = User.new(params[:user])
@@ -130,10 +130,10 @@ class UsersController < ApplicationController
UserMailer.welcome_email(@user).deliver
format.html { redirect_to(@user, :notice => 'User was successfully created.') }
- format.xml { render :xml => @user, :status => :created, :location => @user }
+ format.json { render :json => @user, :status => :created, :location => @user }
else
format.html { render :action => "new" }
- format.xml { render :xml => @user.errors, :status => :unprocessable_entity }
+ format.json { render :json => @user.errors, :status => :unprocessable_entity }
end
end
end