HTML页面跳转 点击数:42 | 回复数:2 | 最后回复发表于2009.09
1楼

-
116.233.231.*
-
发表于 2009.09.17 22:22:42
1.
<html>
<body>
<meta http-equiv="refresh" content="0;url=http://88223100.cnblogs.com">
</body>
</html>
2.
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>欢迎访问</title>
</head>
<body onLoad="parent.location='http://88223100.cnblogs.com'">
</body>
</html>
3.
<script language="JAVASCRIPT">
setTimeout("document.location.href="/index.asp'",0);
</script>
放在<body></body>之间就可以了!!
2楼
宁采臣
发表于 2009.09.22 08:45:09
asp跳转方式
<%
response.Redirect("pic.asp")
%>
3楼
宁采臣
发表于 2009.09.22 08:49:13
php跳转
使用PHP自带函数
Header("Location: 网址");
为什么我向另一网页传送变量时,只得到前半部分,以空格开头的则全部丢失
<?php
$Var="hello php";
$post= "receive.php?Name=".urlencode($Var);
header("location:$post");
?>
接收页面你不需要使用Urldecode(),变量会自动编码.
在PHP中用header("location:test.php")进行跳转要注意以下几点:
1、location和“:”号间不能有空格,否则会出错。
2、在用header前不能有任何的输出。
3、header后的PHP代码还会被执行。