国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 編程 > HTML > 正文

html網頁自動跳轉頁面代碼

2024-08-26 00:09:51
字體:
來源:轉載
供稿:網友

網頁自動跳轉頁面的代碼在很多時候都非常的有用,下面的是兩個簡單的例子。僅供參考。

方案一,用<meta>里直接寫刷新語句:

<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=https://www.mycodes.net">
<title>html網頁自動跳轉代碼--西農大網站</title>
</head>
<body>

測試:html網頁自動跳轉代碼<br/>

你可以在這里寫下你想的一切東西!<br />

如:西北農林科技大學是一所985、211院校。<br />

</body>
</html>  

方案二,用JavaScript腳本來跳轉

<html>
<head>

<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<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 = https://www.mycodes.net;} 
}</script>
 </p>
</form><p align="center">

測試:html網頁自動跳轉代碼<br/>

你可以在這里寫下你想的一切東西!<br />

如:西北農林科技大學是一所985、211院校。<br /><br />

如果您的瀏覽器不支持跳轉,<a style="text-decoration: none" ><font color="#FF0000">請點這里</font></a>.</p>
</body>
</html>

運行截圖:



發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 灌南县| 同江市| 富顺县| 东至县| 襄樊市| 华阴市| 邻水| 道真| 会同县| 鄄城县| 通江县| 虞城县| 辰溪县| 永康市| 濮阳市| 衡南县| 翼城县| 正镶白旗| 崇州市| 龙海市| 房产| 古浪县| 新泰市| 南投市| 集贤县| 定陶县| 梁河县| 察雅县| 巴楚县| 南投市| 九龙县| 兴仁县| 长春市| 虹口区| 安平县| 澄城县| 尼木县| 澄城县| 元江| 亚东县| 北流市|