zoukankan      html  css  js  c++  java
  • 自动关闭窗口的方法

    <!DOCTYPE html>
    <html>
    <head>
        <meta charset="utf-8" />
        <title>网摘保存提示</title>
        <link type="text/css" href="/css/wz_new.css" rel="Stylesheet" />
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <script type="text/javascript">
    
            function closeIt() {
                //window.open("http://wz.cnblogs.com/mywz/","newwindows");
                self.close();
            }
    
            function doclose()
            {
                setInterval("autoclose()",1000);
            }
            function autoclose()
            {
                var timeNum=document.getElementById("time").innerHTML;
                if(timeNum <= 1)
                    closeIt();
                document.getElementById("time").innerHTML = timeNum - 1;
                if (timeNum < 1)
                    document.getElementById("block_temp").innerHTML = "";
            }
        </script>
    </head>
    
    <body bgcolor="white" onload="doclose();" style="margin:0px;padding:0px;">
    
        <div id="wrapper">
            <div style="margin-top:140px;text-align:center;font-size:12px;">
                <span style="font-size:20px;font-weight:bold">Success!</span><br />
                <div style="margin:0 auto;text-align:center;">
                    网摘保存成功!<br />
                    <span id="block_temp"><span id="time">2</span>秒后<a href="javascript:void(0);" onclick="closeIt()">自动关闭</a>   <a href="/my/" target="_blank">查看我的网摘</a></span>
                </div>
            </div>
        </div>
    </body>
    </html>
    
  • 相关阅读:
    文件下载断点续传插件webupload插件
    cocos2dx 2.x 粒子渲染时有黑色粒BUG
    VOIP NAT穿越之SIP信令穿越
    hdu 5086 Revenge of Segment Tree(BestCoder Round #16)
    [并发]线程池技术小白
    调用 COM 对象
    switch-case 执行顺序
    HDELETE
    python and java
    部分查询练习题及答案
  • 原文地址:https://www.cnblogs.com/qqhfeng/p/12573016.html
Copyright © 2011-2022 走看看