Welcome Guest, Not a member yet? Register   Sign In

[quote author="bretticus" date="1252312780"]There really is no reliable way to detect session expiration. CI cookie sessions are not truly sessions in the traditional sense. CI sessions store all the session data in a cookie. Using PHP sessions, for example, all the information is stored on the server with a cookie that has the session key to "unlock" the session data per user. (I should not that CI sessions in database mode work more like traditional sessions.)

HTTP is stateless and there is no notion of session. In fact, cookies are a session imitating "hack." Thus, there's no execution hook for statelessness. The browser requests a page, the server returns the request all at once. Smile

What you should do is setup a cron job to run a PHP/Perl/Python/Ruby/Bash script that checks to see how old the data is and if it meets a certain criteria (30 minutes since last update) then delete it (PHP session handling basically does this as garbage collection except it probably occurs when PHP is executed rather that on a timer.)[/quote]

thanks man.

Messages In This Thread
session - by El Forum - 09-06-2009, 04:03 PM
session - by El Forum - 09-06-2009, 09:39 PM
session - by El Forum - 09-06-2009, 09:41 PM
session - by El Forum - 09-07-2009, 08:10 AM
session - by El Forum - 09-07-2009, 10:01 AM
session - by El Forum - 09-07-2009, 11:55 AM

Theme © iAndrew 2016 - Forum software by © MyBB