作為網站運營者,有時候經常會用到某一個頁面跳轉到另外一個頁面。找的好多代碼要么不兼容,要么體驗很差、要么跳轉速度不是很快。今天凡高網絡小編給大家搜集和整理了幾個非常實用的代碼。供大家學習和參考。
方案一,用<meta/>里直接寫刷新語句:
<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://www.51rgb.com"/>
<title>html網頁自動跳轉代碼--凡高網絡網站</title>
測試:html網頁自動跳轉代碼
你可以在這里寫下你想的一切東西!
如:西安凡高網絡專業網站建設公司。
方案二,用javascript腳本來跳轉
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"/>
<title>正在進入凡高網絡網站</title>
<form name="loading"> </form>
正在進入,請稍等...
<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;"/>
[xss_clean]