html 網(wǎng)頁(yè)自動(dòng)跳轉(zhuǎn)代碼
網(wǎng)頁(yè)的跳轉(zhuǎn)在很多時(shí)候都非常的有用,下面的是兩個(gè)簡(jiǎn)單的例子。僅供參考。
<meta>
里直接寫刷新語(yǔ)句:<html>
<head>
<meta http-equiv="Content-Language" content="zh-CN">
<meta HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=gb2312">
<meta http-equiv="refresh" content="5;url=http://o2fo.com/search">
<title>html網(wǎng)頁(yè)自動(dòng)跳轉(zhuǎn)代碼--W3Cschool</title>
</head>
<body>
測(cè)試:html網(wǎng)頁(yè)自動(dòng)跳轉(zhuǎn)代碼<br/>
你可以在這里寫下你想的一切東西!<br />
如:W3Cschool是一個(gè)專業(yè)的編程入門學(xué)習(xí)網(wǎng)站。<br />
</body>
</html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>正在進(jìn)入W3Cschool</title>
</head>
<body>
<form name=loading>
<p align=center> <font color="#0066ff" size="2">正在進(jìn)入,請(qǐng)稍等</font><font color="#0066ff" size="2" face="Arial">...</font>
<input type=text name=chart size=46 style="font-family:Arial; font-weight:bolder; color:#0066ff; background-color:#fef4d9; padding:0px; border-style:none;">
<input type=text name=percent size=47 style="color:#0066ff; text-align:center; border-width:medium; border-style:none;">
<script>
var bar=0
var line="||"
var amount="||"
count()
function count(){
bar=bar+2
amount =amount + line
document.loading.chart.value=amount
document.loading.percent.value=bar+"%"
if (bar<99)
{setTimeout("count()",100);}
else
{window.location = "http://o2fo.com/search";}
}</script>
</p>
</form><p align="center">
測(cè)試:html網(wǎng)頁(yè)自動(dòng)跳轉(zhuǎn)代碼<br/>
你可以在這里寫下你想的一切東西!<br />
如:W3Cschool是一個(gè)專業(yè)的編程入門學(xué)習(xí)網(wǎng)站。<br /><br />
如果您的瀏覽器不支持跳轉(zhuǎn),<a style="text-decoration: none" href="http://o2fo.com/search"><font color="#FF0000">請(qǐng)點(diǎn)這里</font></a>.</p>
</body>
</html>
運(yùn)行截圖: