Forum Moderators: phranque
<SCRIPT language=JavaScript type="text/javascript"> <!--
function logout()
{
self.open("logout.jsp", "logout","width=100, height=100");
}
function checkClose() // for IE
{
if ((window.event.clientY < 0) ¦¦ (window.event.clientX < 0))
logout();
}
//--></SCRIPT>
HTML
<BODY onUnload="javascript:checkClose()">
I know this looks klugey but it works on the principle that the X in the upper right corner has negative (x,y) coordinates