Immediate thought
Malwareyou cant close this page unless you buy something
your pc is infected send us moneyYou are not supposed to take control of the browser
Imagine if you could not close a web browser when you went to some site on the internet that was loading your computer full of viruses!
lookup
onclose
onunload
something like
<script language="JavaScript">
<!--
var legalExit=0;
var lpx=10;
function leave() {
if(legalExit==0) {
var dl=confirm('WARNING: Closing this window means bla bla bla.\n\nClick OK to remain.');
if(dl) {
if(window.screen){
lpx=screen.width;lpx=lpx-225;
}
var op=window.open('filename','','width=170,height=185,location=no,status=no,directories=no,toolbar=no,menubar=no,scrollbars=yes,resizable=no,top=10,left=' + lpx);
}
}
}
function openWin(u,t,x,y,s) {
var op=window.open(u,t,'width='+x+',height='+y+',location=no,status=yes,toolbar=no,directories=no,menubar=no,scrollbars='+s+',resizable=no');
op.focus();
}
// -->
</script>
code is untested, just thought process