导航:首页 > 编程语言 > url跳转代码

url跳转代码

发布时间:2023-10-12 20:12:20

A. URL跳转的几种方式

1、:

<head><!--以下方式只是刷新不跳转到其他页面--><metahttp-equiv="refresh"content="10"><!--以下方式定时转到其他页面--><metahttp-equiv="refresh"content="5;url=hello.html"></head>

2、javascript:

①、window.location.href方式

js"><scriptlanguage="javascript"type="text/javascript">//以下方式直接跳转window.location.href='hello.html';
//以下方式定时跳转setTimeout("javascript:location.href='hello.html'",5000);
</script>

②、window.navigate方式跳转

<scriptlanguage="javascript">
window.navigate("target.aspx");</script>

③、window.loction.replace方式

<scriptlanguage="javascript">
window.location.replace("target.aspx");</script>

④、self.location方式

<scriptlanguage="JavaScript">
self.location='target.aspx';</script>

⑤、top.location方式

<scriptlanguage="javascript">
top.location='target.aspx';</script>

⑥、返回方式

<scriptlanguage="javascript">
alert("返回");
window.history.back(-1);</script>
阅读全文

与url跳转代码相关的资料

热点内容
任命文件人字多少号 浏览:27
如何给桌面的文件自动填写序号 浏览:349
压缩文件JPG重命名 浏览:487
vivox7怎么隐藏文件 浏览:340
官网买苹果好处 浏览:153
直播app源码如何搭建 浏览:31
c盘系统文件包介绍图片 浏览:856
linuxopt主要存哪些文件 浏览:924
jsdate天数 浏览:930
qq空间怎样发视频文件在哪里找 浏览:208
nrf2401收发程序 浏览:498
哪个网站看新闻最好 浏览:944
找到文件夹并清除linux 浏览:82
苹果app不安全怎么办 浏览:1000
电脑桌面文件收集软件推荐 浏览:317
桌面的文件夹不能删除不了怎么办 浏览:724
什么是手机温控文件 浏览:840
广东农信app怎么更改预留手机号码 浏览:241
cdm打开隐藏文件夹 浏览:320
贝壳app房子为什么偶尔不显示 浏览:4

友情链接