To display an alert when a page is unloaded: : unload « jQuery « JavaScript DHTML






To display an alert when a page is unloaded:

 


$(window).unload( function () { alert("Bye now!"); } );

   
  

Related examples in the same category

1.Unload event