<!--将如下的 endv.cn 改为要跳转的域名-->
第一种:单域名的跳转
1:域名在服务器端跳转javascript
1 Response.Redirect(http://endv.cn) 2 Response.End
二、若是你的域名要在客户端跳转,能够这样:html
<script language="javascript" type="text/javascript"> window.location="http://endv.cn";; </script>
3:若是你要让域名页面显示几秒钟以后跳转,能够在html代码的<head></head>部分加上这样的域名跳转代码:
<meta http-equiv="refresh" content="3; url=http://endv.cn">
以上三种是也比较常见,比较经常使用的免费域名跳转代码运行平台Win9x WinNT Win2000 WinME WinXP。
4:不隐藏域名跳转以后的地址 java
1 <html> 2 <body> 3 <meta http-equiv="refresh" content="0.1;url=endv.cn"> 4 </body> 5 </html>
5:可隐藏域名跳转以后的地址:服务器
<html> <frameset framespacing="0" border="0" rows="0" frameborder="0"> <frame name="main" src="endv.cn" scrolling="auto" noresize> </frameset> </html>
6:定时的域名跳转代码微信
<meta http-equiv="refresh" content="3;rul=http://endv.cn">
此代码能够让网页在必定的时间内,跳转到另一个网页上,其中content=" 为跳转前停暂的秒数,rul= 为跳转的域名ui
<meta http-equiv="refresh" content="3;rul=http://endv.cn">
此代码能够让网页在必定的时间内,跳转到另一个网页上,其中content=" 为跳转前停暂的秒数,rul= 为跳转的域名。url
第二种:多域名的跳转spa
<script>try {if( self.location == "http://cnblogs.com/endv" ) { top.location.href = "http://域名一/目录"; } else if( self.location == "http://域名二/" ) { top.location.href = "http://域名二/目录"; } else if( self.location == "http://域名三/" ) { top.location.href = "http://域名三/目录"; } else if( self.location == "http://域名四/" ) { top.location.href = "http://域名四/目录"; } else {document.write ("错误的访问地址")}} catch(e) {}</script>
多域名跳转完整示例:(如下域名看好的可微信扫码…^ ^……)code
<!DOCTYPE HTML> <!-- -头部页面描述:START --> <!DOCTYPE html PUBLIC "" ""> <HTML lang="en"> <HEAD> <META charset="UTF-8"> <TITLE>天云信息</TITLE> <script>try { /* ajerp.com */ if( self.location == "http://ajerp.com" ) { top.location.href = "/all/"; // 这里跳转到目录 } else if( self.location == "http://endv.club/" ) { top.location.href = "/all/"; } else if( self.location == "http://endv.cn/" ) { top.location.href = "https://code.endv.cn/"; } /* ajerp.com */ else if( self.location == "http://endv.top/" ) { top.location.href = "/all/"; } else if( self.location == "http://globaladmin.cn/" ) { top.location.href = "/all/"; } else if( self.location == "http://liulaisheng.cn/" ) { top.location.href = "/all/"; } else if( self.location == "http://suqianbao.cn/" ) { top.location.href = "/all/"; } else if( self.location == "https://tianyun.pub/" ) { top.location.href = "/all/"; } else if( self.location == "https://tianyun.space/" ) { top.location.href = "/endv.cn/"; } else if( self.location == "https://ajerp.com" ) { top.location.href = "https://www.endv.cn/all/"; } else if( self.location == "https://endv.club/" ) { top.location.href = "https://www.endv.cn/all/"; } else if( self.location == "https://endv.cn/" ) { top.location.href = "https://www.endv.cn/all/"; } else if( self.location == "https://endv.top/" ) { top.location.href = "./all/"; } else if( self.location == "https://globaladmin.cn/" ) { top.location.href = "/all/"; } else if( self.location == "https://liulaisheng.cn/" ) { top.location.href = "/all/"; } else if( self.location == "https://suqianbao.cn/" ) { top.location.href = "/all/"; } else if( self.location == "https://tianyun.pub/" ) { top.location.href = "/all/"; } else if( self.location == "https://tianyun.space/" ) { top.location.href = "/endv.cn/"; } else { var str = server.htmlEncode("<p><ahref='https://www.endv.cn'>天云信息</a></p>"); document.write(str); //document.write ("错误的访问地址") } } catch(e) {}</script> </HEAD> </HTML>