纯 html 以及 js 多域名跳转
<!--将以下的 endv.cn 改成要跳转的域名-->
第一种:单域名的跳转
1:域名在服务器端跳转
Response.Redirect(http://endv.cn)
Response.End
2、如果你的域名要在客户端跳转,可以这样:
<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:不隐藏域名跳转之后的地址
<html>
<body>
<meta http-equiv="refresh" content="0.1;url=endv.cn">
</body>
</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= 为跳转的域名
<meta http-equiv="refresh" content="3;rul=http://endv.cn">
此代码可以让网页在一定的时间内,跳转到另外一个网页上,其中content=" 为跳转前停暂的秒数,rul= 为跳转的域名。
第二种:多域名的跳转
<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>
多域名跳转完整示例:(以下域名看好的可微信扫码…^ ^……)
<!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>
纯 html 以及 js 多域名跳转的更多相关文章
- js 多域名跳转
<script>try {if( self.location == "http://cnblogs.com/endv" ) { top.location.href = ...
- js实现域名判断后跳转到指定网址
js实现域名判断后跳转到指定网址,也适用于同一虚拟空间放多个网站: <script> try { if(self.locatio ...
- centos LAMP第二部分apache配置 下载discuz!配置第一个虚拟主机 安装Discuz! 用户认证 配置域名跳转 配置apache的访问日志 配置静态文件缓存 配置防盗链 访问控制 apache rewrite 配置开机启动apache tcpdump 第二十节课
centos LAMP第二部分apache配置 下载discuz!配置第一个虚拟主机 安装Discuz! 用户认证 配置域名跳转 配置apache的访问日志 配置静态文件缓存 配置防盗链 ...
- js实现QQ跳转到支付宝APP并领取红包!附:动图demo
前天我在sg开源了js实现微信跳转到支付宝并领红包的代码.https://segmentfault.com/a/11...于是朋友圈开始刷屏,各种套路,各种标题,再附上短链接,引起了很多人的好奇,然后 ...
- Apache Rewrite实现URL的跳转和域名跳转
Apache Rewrite实现URL的跳转和域名跳转 Rewirte主要的功能就是实现URL的跳转,它的正则表达式是基于Perl语言.可基 于服务器级的(httpd.conf)和目录级的 (.h ...
- JS阻止链接跳转代码
刷新后focus在第一个标签 onload="$('#input_email').focus(); " $(document).ready(function(){ $(" ...
- [HTML]js实现页面跳转,页面A跳到另一个页面B.以及页面传值(中文)
要实现从一个页面A跳到另一个页面B,js实现就在A的js代码加跳转代码 JS跳转大概有以下几种方式: 第一种:(跳转到b.html)<script language="javascri ...
- js获取域名的方法
本文实例讲述了js获取域名的方法.分享给大家供大家参考.具体实现方法如下: 复制代码代码如下: <script>//获取域名var k_host = window.location.hos ...
- asp 域名跳转
域名跳转 将xxx.cn定向到www.xxx.com dim querys,Urls Urls = "http://www.xxx.com"&Request.ServerV ...
随机推荐
- Codeforces Round #356 (Div. 2) C. Bear and Prime 100 水题
C. Bear and Prime 100 题目连接: http://www.codeforces.com/contest/680/problem/C Description This is an i ...
- SGU 405 Totalizator
405. Totalizator Time limit per test: 0.25 second(s)Memory limit: 65536 kilobytes input: standardout ...
- web开发中兼容性问题(IE8以上含)持续更新~~
在实际开发中总是遇到莫名其妙的问题~~~那么就记录下来这些问题,对这些问题进行一个总结. 1.事件对象 1)事件参数e,就是事件对象,标准的获取方式 2)e.eventPhase 事件阶段,IE8以前 ...
- 华为S5300系列交换机V100R005SPH008热补丁
S23_33_53-V100R005SPH008.pat 附件: 链接:https://pan.baidu.com/s/1XfIQ55g5pWI9aqmM7LHUew 密码:f2mu
- LM358资料及引脚图
LM358里面包括有两个高增益.独立的.内部频率补偿的双运放,适用于电压范围很宽的单电源,而且也适用于双电源工作方式,它的应用范围包括传感放大器.直流增益模块和其他所有可用单电源供电的使用运放的地方使 ...
- hybrid App h5二级页面返回的时候保持与一级页面浏览的位置一致
最近在开发公司hybrid app的时候,需要将原本原生的配置中心模块统一变更为H5,做完之后从测试那里反馈回来这样一个问题,当滑到页面底部或中部的时候进入子页面进行设置,返回的时候页面应该定位到离开 ...
- Xsolla和Crytek合作,对游戏战争前线推出全新支付方式
新闻稿: Sherman Oaks, 加州 (美国) –2014年 10月 15日-计费提供商Xsolla今日正式宣布.和著名游戏开发商以及发行商 Crytek.这次合作意味着玩家能够期待大量的游戏内 ...
- Spring Boot整合RabbitMQ详细教程
原文:https://blog.csdn.net/qq_38455201/article/details/80308771 1.首先我们简单了解一下消息中间件的应用场景 异步处理 场景说明:用户注册后 ...
- 关于deselectRowAtIndexPath
有没有遇到过,导航+UITableView,在push,back回来之后,当前cell仍然是选中的状态.当然,解决办法简单,添加一句[tableView deselectRowAtIndexPath: ...
- IOS中为tableViewCell增加右侧标记(选中或者更多)
if ([self.selectWys containsObject:[self.initCitys objectAtIndex:indexPath.row]]) { tvCell.accessory ...