|
Posted by Vaibhav Sibal on 03/15/05 20:06
Hi
I wanted to implement an auto-logout feature for my project so that if
a terminal is left unattended for say 10 minutes, it should
automatically logoff the user. Apart from this, there is another
problem that I am encountering with my authentication scheme, the
scene is as follows :
(1) I am using a $_SESSION variable to transfer the username across
pages, what happens is that I cannot login more than one user from the
same machine since if i try the same the SESSION[username] variable's
value gets changed to the most latest login name. How do i get around
this ?
(2) Secondly, What happens is, when the user logs off from the system,
there are two things that happen at that time, first is that the
session variable is killed manually. The second is that the logged in
status of the user is updated in the database. So what happens is that
when the user is logged on the system, the database shows the user
logged in status as 1 otw it shows it as 0. Now the problem is that if
by chance the user closes the current browser window without actually
logging off, the session variable gets killed automatically but the
database is not updated accordingly. Please suggest some way around
this also.
I would be really happy if you guys can help me with this.
Thanks in advance
Vaibhav
Navigation:
[Reply to this message]
|