Yes, this is normal. Old sessions are cleaned up by
$sess->gc occasionally.
Have a look at pages/showoff.php3 for a demo of printing current sessions.
There is no way of knowing when a session is *really* active. I guess you could force a garbage collection before pulling the data from the active session table.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have the same problem. As far as I can tell ac_delete in ct_sql.inc should delete the entrie in the active_sessions table when you call:
$auth->logout();
$sess->delete();
But for some reason this doesnt happen. Does anybody konw why?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
And the session is still not deleted. I am afraid I don't have access to the database-logs.
A follow-up: If I get this to work someday, will the sessions also be deleted from the database when the browser is closed? If not, does anybody have some sample-code on how to force a delete from active_sessions when the browser closes?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The Active Session DB is used to store data of
the "active sessions" running. right?
But afer logout, the entries in this table are not
deleted. I ask you why? This is normal? And what I
should do to delete it.
I am using command auth->logout and session->delete
but the entries doen't dissapear.
Plz explain me this someone.
And how I can print the number of active users logged at the same moment if this active session table is always full of garbage?
Thks!!
(sorry to post it before in the wrong place)
Yes, this is normal. Old sessions are cleaned up by
$sess->gc occasionally.
Have a look at pages/showoff.php3 for a demo of printing current sessions.
There is no way of knowing when a session is *really* active. I guess you could force a garbage collection before pulling the data from the active session table.
Hi
I have the same problem. As far as I can tell ac_delete in ct_sql.inc should delete the entrie in the active_sessions table when you call:
$auth->logout();
$sess->delete();
But for some reason this doesnt happen. Does anybody konw why?
Sorry Ignery, I didn't read your question properly.
Are you both perhaps calling:
$auth->logout();
$sess->delete();
page_close();
Of course the page_close() updates the session, inserting it back into the session table!!
If not, have a look in your database logs to see which queries are being executed.
...R.
I'm doing this:
page_open( array( "sess" => "acta_sess", "auth" => "acta_default_auth" ) );
$auth->logout();
$sess->delete();
Header( "Location: velkommen.html" );
exit();
And the session is still not deleted. I am afraid I don't have access to the database-logs.
A follow-up: If I get this to work someday, will the sessions also be deleted from the database when the browser is closed? If not, does anybody have some sample-code on how to force a delete from active_sessions when the browser closes?