- UID
- 587971
- 帖子
- 1
- 精华
- 0
- 贡献
- 0
- 推广
- 0
- 有效BUG
- 0
- 注册时间
- 2015-7-7
|
我这边是W10的系统,前面贴吧用过一个大神给的代码。但是换了W10后就用不了了,只要一用就重新跳出一个窗口出来。
javascriptfunction(){var intv=prompt('#Secs. between reloads?','60');if(intv&&!isNaN(intv)){with(document){write('<html><frameset rows=\'*,22\' framespacing=0 border=0 frameborder=no><frame noresize frameborder=no><frame scrolling=no noresize frameborder=no></frameset></html>');frames[0].location.href=document.location.href;var docstr='<html><center><body bgcolor=cyan style=\'margin-top:0px\'>\n';docstr+='Reloading in <span id=\'caption\'></span>secs.</body></center>\n';docstr+='<script>\nvar reloadIntv='+intv+';\nvar secsLeft='+intv+';\nfunction reloadFrame(){secsLeft=reloadIntv+1;parent.frames[0].location.href=parent.frames[0].location.href;}\nfunction countDown(){secsLeft--;showTime();}\nfunction showTime(){document.getElementById(\'caption\').innerHTML=parseInt(secsLeft)+\' \';}\nsetInterval(\'reloadFrame()\','+intv*1000+');\nsetInterval(\'countDown()\',1000);\nshowTime();\n</script>\n</html>';frames[1].document.write(docstr);}}})() |
|