I am using mozilla firefox 1.5. I want to delay the page close when the user clicks on the close (X) button of the browser. I want to display something like "Closing Please wait......" for 5 seconds (run a code in the background) and then close the window after 5 seconds.
Till the time the "Closing Please wait......" is displayed, the window should not close. after 5 seconds, it will as it is close because the user has clicked the browser's close button.
Is there a way I can do this ?