Latest News

Home » 網站架設網頁設計教學 » 如何讓網頁自動跳轉代碼html方案

如何讓網頁自動跳轉代碼html方案

如何讓網頁自動跳轉代碼html方案
網頁自動跳轉代碼html方案一
<html>
<head>
<meta http-equiv=”Content-Language” content=”zh-tw”>
<meta HTTP-EQUIV=”Content-Type” CONTENT=”text/html; charset=utf-8″>
<meta http-equiv=”refresh” content=”0.1;url=http://www.goto1688.tw”>
<title></title>
</head>
<body>
</body>
</html>

網頁自動跳轉代碼html方案二
<html>
<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=utf-8″>
<title>正在進入</title>
</head>
<body>
<form name=loading>
<p align=center> <font color=”#0066ff” size=”2″>正在進入,請稍等</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://要轉跳連結之網址”;}
}</script>
</p>
</form>
<p align=”center”> 如果無法跳轉跳轉,<a style=”text-decoration: none” href=”http://www.731000.cn”><font color=”#FF0000″>請點這裡</font></a>.</p>
</body>
</html>
限時網頁自動跳轉
網頁自動跳轉代碼html專案
腳本說明:
把如下代碼加入<body>區功能變數中
<SCRIPT LANGUAGE=”JavaScript”>
<!– Begin
var start=new Date();
start=Date.parse(start)/1000;
var counts=10;
function CountDown(){
var now=new Date();
now=Date.parse(now)/1000;
var x=parseInt(counts-(now-start),10);
if(document.form1){document.form1.clock.value = x;}
if(x>0){
timerID=setTimeout(“CountDown()”, 100)
}else{
location.href=”http://要轉跳連結之網址”
}
}
// End –>
</script>
<SCRIPT LANGUAGE=”JavaScript”>
<!–
window.setTimeout(‘CountDown()’,100);
–>
</script>
<FORM NAME=”form1″>
<INPUT TYPE=”text” NAME=”clock” SIZE=”2″ VALUE=”10″>
10秒後自動跳轉網頁
</FORM>
————————————————————————–

About

發佈留言