【发布时间】:2010-02-18 00:23:26
【问题描述】:
我正在使用 Authlogic,我想在我的控制器中实现基本 HTTP 身份验证,以便我可以定义哪些操作需要身份验证。
我知道如何进行基本 HTTP 身份验证 authenticate_or_request_with_http_basic 和 before_filter,但我想在这里从其他如何使用 Authlogic 插件实现它。
class ItemsController < ApplicationController
before_filter :authenticate , :only => [:index, :create]
...
end
【问题讨论】:
标签: ruby-on-rails authentication authlogic