...

View Full Version : Detect when user browser goes to another web site



turnbui
01-14-2007, 02:02 PM
Hello folks,
Is there any way that an Apache server can recognise that a users browser has changed from your web site to another site. ie. is there a way of executing a CGI based on when the address bar no longer has your FDQN.
Would this be via Javascript [if possible?] or ???

Sorry for this naive question):

Thanks

felgall
01-14-2007, 07:58 PM
Depending on how the visitor has their browser and firewall configured the site they have reached might be able to identify that they came from your site or it might not. The code to test for it would have to be on the site that they go to though because once they leave your site you have no way to run anything.

1212jtraceur
01-14-2007, 11:41 PM
You could have an onunload event listener to do something when window.location.href changes. You would have to disable that event listener when a link to somewhere else on your site is clicked. It's not a perfect solution (it will not handle manual changes of window.location.href) but it may be sufficient for your situation.

turnbui
01-16-2007, 04:36 PM
Thanks for your replies. I'll have to give it up unfortunately.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum