How to catch that a user do close his/her browser?

S

sok06

When I user decisedes to leave my site. How can I detect that imidietly and trigger code to run from that?

best regards
Rickard

**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...
 
S

sok06

As I have understood it Global.asa can only use four differetn event handlers, and I am looking for some way to catch the fact that some user have pressed "close" on the browser X. Is it really possible to use global.asa for that purpose?

Rickard

**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...
 
J

J. Baute

first of all this isn't an ASP question, but more a JavaScript/clientside
scripting question, so you'll have more luck getting an answer in the
appropriate scripting newsgroups,
second I can tell you there really isn't a way to do this properly,
you can try faking it, but there will always be situations where this won't
work,

perhaps if you explain -what- exactly you are trying to do, we can give you
a proper serverside solution?


Rickard Sok said:
As I have understood it Global.asa can only use four differetn event
handlers, and I am looking for some way to catch the fact that some user
have pressed "close" on the browser X. Is it really possible to use
global.asa for that purpose?
Rickard

**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP &
ASP.NET resources...
 
J

John Blessing

Rickard Sok said:
When I user decisedes to leave my site. How can I detect that imidietly
and trigger code to run from that?
best regards
Rickard

**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP &
ASP.NET resources...

You can't. You should find another way to do what you need.

You might be able to do something in client-side javascript
(http://developer.irt.org/script/1578.htm), but all these methods can be
got around.

Eventually the session will timeout (and if you are lucky - see
http://www.aspfaq.com/show.asp?id=2078), the session_onend event will fire.

--
John Blessing

http://www.LbeHelpdesk.com - Help Desk software priced to suit all
businesses
http://www.free-helpdesk.com - Completely free help desk software !
http://www.lbetoolbox.com - Remove Duplicates from MS Outlook
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,734
Messages
2,569,441
Members
44,832
Latest member
GlennSmall

Latest Threads

Top