html 百度一下 跳转的代码是多少

如题所述

第1个回答  2019-05-09
这个就是了,测试了好多种的,这个是5秒之后跳转的代码,时间可以自己改
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>5秒后跳转到另一个页面</title>
</head>
<script>
var t = 5;
var s = '.';
timeID=setInterval("countDown()",1000);
function countDown(){
time.innerHTML= t +"秒后跳转"+s;
t--;
s+='.';
if (t==0) {
location.href="http://www.51zuoyi.com/"; //【这边是要跳转的目标地址】
clearInterval(timeID);
}
}
</script>
<body>

<div><font ID="time" face="impact" color="#272822" size="7">即将跳转</font>
</div>
</body>
</html>
把目标网址改为自己的就可以实现跳转了
第2个回答  2018-06-08
实现跳转的代码吗?
<a href="url"></a>
window.location="url"....