Return to Snippet

Revision: 37746
at December 16, 2010 18:21 by gmericksen


Initial Code
#User.rb
 acts_as_authentic do |c|
    c.logged_in_timeout = 10.minutes # default is 10.minutes
  end

#UserSession.rb
class UserSession < Authlogic::Session::Base
    logout_on_timeout true # default if false
  end

Initial URL
http://adf.ly/91637/banner/rdoc.info/github/binarylogic/authlogic/master/Authlogic/Session/Cookies/Config:remember_me_for

Initial Description
This will require a user to log back in if they are inactive for more than 10 minutes. In order for this feature to be used you must have a last_request_at datetime column in your table for whatever model you are authenticating with.

Initial Title
Authlogic Timeout

Initial Tags
rails

Initial Language
Rails