View Single Post
  #5 (permalink)  
Old July 19th, 2005, 05:29 AM
prophet prophet is offline
Authorized User
Join Date: Jul 2005
Location: Westchester County, NY, USA.
Posts: 17
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to prophet Send a message via MSN to prophet

In Internet Explorer the onBeforeUnload event allows you to prompt the user if the browser is about to be closed, or the page is being navigated elsewhere.


<script language="javascript">
function handleOnBeforeUnload() {
  event.returnValue = "Some custom message in here.";


<body onBeforeUnload="handleOnBeforeUnload();">

Reply With Quote