提示框页面:
<head runat="server"> <title>提醒</title> <bgsound src="你有新的消息,请注意查收!hun(NEW59).mp3" /> </head> <body οnlοad="movePFW()" background="Images/game_ysxz.gif"> <form id="form1" runat="server"> <div> 这是一个右下脚弹出的提示框<br /> 用来提醒用户用的</div> </form> <script language="javascript"> window.resizeTo(220,210); var windowW=220 // wide var windowH=210 // high var Yoffset=0 // in pixels, negative values allowed var windowStep=2 // move increment (pixels) var moveSpeed=12 // move speed (larger is slower) Xoffset=25; var windowX = (screen.width/2)-(windowW/2); windowX=screen.availWidth-Xoffset-windowW; var windowY = (screen.availHeight); var windowYstop = windowY-windowH-Yoffset; var windowYnow = windowY; window.focus (); resizeTo(windowW,windowH); moveTo(windowX,windowY); function movePFW() { if (document.all) { if (windowYnow>=windowYstop){ moveTo(windowX,windowYnow); windowYnow=windowYnow-windowStep; timer=setTimeout("movePFW()",moveSpeed); } else { clearTimeout(timer); setTimeout("moveBack()",120000 ) moveTo(windowX,windowYstop); } } else { moveTo(windowX,windowYstop); } } function moveBack() { if (document.all) { if (windowYnow<=windowY) { moveTo(windowX,windowYnow); windowYnow=windowYnow+windowStep; timer1=setTimeout("moveBack()",moveSpeed); } else { clearTimeout(timer1); moveTo(windowX,windowY); self.close() } } else { moveTo(windowX,windowYstop); self.close() } } </script> </body>
主页面:
<head runat="server"> <title>无标题页</title> <script language="javascript"> function showSmallPage() { window.open('Default3.aspx','','top=1000,left=1000'); } </script> </head> <body οnlοad="showSmallPage();">