浏览器网页定时刷新代码教程分享

浏览器网页定时刷新代码教程分享,只需要一段js代码

首先F12打开控制器面板,复制刷新代码

timeout=prompt("Set timeout (Second):");count=0current=location.href;if(timeout>0)setTimeout('reload()',1000*timeout);elselocation.replace(current);function reload(){setTimeout('reload()',1000*timeout);count++;console.log('每('+timeout+')秒自动刷新,刷新次数:'+count);fr4me='<frameset cols=\'*\'>\n<frame src=\''+current+'\'/>';fr4me+='</frameset>';with(document){write(fr4me);void(close())};}
转载请注明来源: 陌涛小站 / 文章链接:
正文到此结束
吐槽 0发

发表评论

您的电子邮箱地址不会被公开。 必填项已用 * 标注

This site uses Akismet to reduce spam. Learn how your comment data is processed.