1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Fix Basic Authentication examples

This commit is contained in:
Sebastian Martinez 2011-03-28 22:49:43 -03:00
parent 70779a08a0
commit 54af8dfbfc
2 changed files with 3 additions and 3 deletions

View file

@ -619,7 +619,7 @@ HTTP basic authentication is an authentication scheme that is supported by the m
<ruby> <ruby>
class AdminController < ApplicationController class AdminController < ApplicationController
http_basic_authenticate_with :name => "humbaba", "5baa61e4" http_basic_authenticate_with :name => "humbaba", :password => "5baa61e4"
end end
</ruby> </ruby>

View file

@ -1210,7 +1210,7 @@ To use the authentication system, we specify it at the top of our +PostsControll
<ruby> <ruby>
class PostsController < ApplicationController class PostsController < ApplicationController
http_basic_authenticate_with :name => "dhh", "secret", :except => :index http_basic_authenticate_with :name => "dhh", :password => "secret", :except => :index
# GET /posts # GET /posts
# GET /posts.xml # GET /posts.xml
@ -1225,7 +1225,7 @@ We also only want to allow authenticated users to delete comments, so in the +Co
<ruby> <ruby>
class CommentsController < ApplicationController class CommentsController < ApplicationController
http_basic_authenticate_with :name => "dhh", "secret", :only => :destroy http_basic_authenticate_with :name => "dhh", :password => "secret", :only => :destroy
def create def create
@post = Post.find(params[:post_id]) @post = Post.find(params[:post_id])