header("refresh:3;url=http://www.yanue.net");//限时跳转
header('location:http://www.yanue.net');//立即跳转
2. HTML Meta refresh 刷新与跳转(重定向)页面
refresh出现在http-equiv属性中,使用content属性表示刷新或跳转的开始时间与跳转的网址
<Meta http-equiv="refresh" content="3; url=http://www.yanue.net">
<script type='text/javascript'>
// 立即跳转
window.location.href = 'http://www.yanue.net';
// 限时跳转
setTimeout(function(){
// 3秒后跳转
window.location.href = 'http://www.yanue.net';
},3000);
</script>
js实现跳转主要用到location对象
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。