|
-
Jun 7th, 2001, 06:41 AM
#1
Thread Starter
Hyperactive Member
session timeout -session on_end problem
Hi there!
Once a user logs in to my site, he should not be allowed to login from elsewhere. For this reason, I am setting a flag to true in the database when the user logs in, and setting the flag to false when he logs out. This works well, when the user logsout via the 'logout' page in the site. But on the other hand if he closes the browser, I am setting the flag to false in the database in session_onEnd event of global.asa file. But, session_onEnd() event doesn't fire always especially when the server is busy. This is the problem. So if a user forgot to logout, and he comes back next time, still the flag is on. So he is not allowed to logon.
Please help me. Is there anyother method to solve this problem?
BTW, does Response.Redirect work in Session_onEnd() event? If so, will it work even when the browser is closed?
Thanks in advance.
-
Jun 7th, 2001, 01:15 PM
#2
Lively Member
-
Jun 7th, 2001, 01:18 PM
#3
Frenzied Member
Sonia's got a point, but... sessions expire (about 20 minutes is the default). Why not have this flag expire. This will require a watchdog routine to turn off expired flags, and it will require touching active ones with each action.
It is just an idea. TIAMTOW.
Travis, Kung Foo Journeyman
As always, RTFM.
WWW Standards: HTML 4.01, CSS Level 2, ECMA 262 Bindings to DOM Level 1, JavaScript 1.3 Guide and Reference
Perl: Learn Perl, Llama, Camel, Cookbook, Perl Monks, Perl Mongers, O'Reilly's Perl.com, ActiveState, CPAN, TPJ, and use Perl;
YBMS, but Mozilla doesn't.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|