<!DOCTYPE html><html>?<head>? <title>瀏覽器對象</title> ?? <meta http-equiv="Content-Type" content="text/html; charset=gkb"/> ???</head>?<body><h1>操作成功</h1><span id="first">5</span><span>秒后返回到主頁</span><a href="javascript:back();">返回</a><script type="text/javascript">? ? var num=document.getElementById("first").innerHTML;? ? function con(){? ? ? ? num--;? ? ? ? ?document.getElementById("first").innerHTML=num;? ? ? ? ?if(num==0){? ? ? ? ? ? ?location.assign("www.xianlaiwan.cn");? ? ? ? ?}? ? }? ? setInterval("con()",1000);? ? function back()? ? {?? ? ? ? window.history.back();? ? }</script></body></html>
要哭了,為什么我設置的返回沒用?
小幸運17
2016-06-21 16:33:47