Hovedside, herfra åbnes popup vinduet...
<html>
<head>
<script>
theUrl="popup.html"
function doThePopUp(){
reWin=window.open(theUrl,'hell','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=200,height=300,top=100,left=100')
}
</script>
</head>
<body>
<a href="javascript:doThePopUp()">Open Popup</a>
</body>
</html>
Selve popup-vinduet: popup.html
<html>
<head>
<script>
theUrl = 'popup.html'
lockU = 1
function doAgain(){
if (lockU == 1){
reWin=window.open(theUrl,'','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=200,height=300,top=100,left=100')
}
}
</script>
<title>Agree With Me!</title>
</head>
<body onunload="doAgain()" bgcolor="#FF0000" link="#FFFF00" vlink="#FFFF00" alink="#FFFF00">
<font color="#FFFFFF" size="2" face="Arial">
You cannot close this window until you agree with me.</font>
<p><font color="#FFFFFF" size="2" face="Arial">Clicking on the 'x' close on the titlebar won't do it.
Right-clicking on the taskbar button and clicking on 'close' won't do it. Alt-F4
won't do it.</font></p>
<p><font color="#FFFFFF" size="2" face="Arial">If you wanna get rid of me, you have to agree with me...</font></p>
<p><a href="javascript:lockU=0;self.close()">I agree.</a></p>
</body>
</html>
|