How i can undrestand a client user is exited from Web Application?
-
Hi all, I want change a field in my database when a user leave whole of web application . How i can underestand that a user leave Web Application then i change my data base. I realy need your immediate help, Thank You
Hoda
Saba02 wrote:
I realy need your immediate help,
Of course you do. But, if you searched for this question, you'd find it's been asked many times before. There's no foolproof way to know, you can do some stuff with AJAX to try to make it foolproof, and that will work 99% of the time. If your app has users logging in, I'd just have a logout functionality, and a timeout so that if they don't log out, they get logged out after a reasonable amount of time. Otherwise, if you google, as I said, there's a client side event you can use to fire an ajax call telling you that they have left a page, then you can basically log them in and out, once for every page they visit.
Christian Graus Driven to the arms of OSX by Vista.
-
Hi all, I want change a field in my database when a user leave whole of web application . How i can underestand that a user leave Web Application then i change my data base. I realy need your immediate help, Thank You
Hoda
The only way is to use the session and store handle your database when the session expires But, I'd like to know what you need to store in database when the client exits
foreach(Minute m in MyLife) myExperience++;
-
The only way is to use the session and store handle your database when the session expires But, I'd like to know what you need to store in database when the client exits
foreach(Minute m in MyLife) myExperience++;
Mohammed Gouda wrote:
The only way is to use the session and store handle your database when the session expires
That's not true, as I said, it's possible using AJAX to know when a client leaves a page, even if they do it by closing the browser.
Christian Graus Driven to the arms of OSX by Vista.
-
Hi all, I want change a field in my database when a user leave whole of web application . How i can underestand that a user leave Web Application then i change my data base. I realy need your immediate help, Thank You
Hoda
Take a look at global.asa(x) or maybe you can solve this with some javascript. ex body onUnload
--------------- www.serverside.no