Forum Moderators: open

Message Too Old, No Replies

Pop up window when browser close

         

sobinbabue

9:23 pm on Jun 2, 2008 (gmt 0)

10+ Year Member



Hi,

I need to show a pop up when user closes the browser with a particular php page opened. How can I do that?

penders

10:32 pm on Jun 2, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



You can only hope to do this if the user closes your webpage, not the browser as a whole. You could try to call window.open() in the onunload event of the body element.

However, unless you are writing a specific app for a select group of users, this behaviour will be very annoying!

And in the real world any sensible pop-up blocker is likely to block any such popup, so it may not even be possible.