您现在的位置是:首页 > 网站建设常见问答网站建设常见问答

301重定向跳转页面asp/php代码写法

2014-12-25【网站建设常见问答】2250 人已围观

简介ASP下的301转向代码: <%@ Language=VBScript %> <% Response.Status=\"301 ...

ASP下的301转向代码:

<%@ Language=VBScript %>
<%
Response.Status=\"301 Moved Permanently\"
Response.AddHeader \"Location\",\"http://www.0574nb.cn\"
%>
ASP.Net下的301转向代码:

<script runat=”server”>
private void Page_Load(object sender, System.EventArgs e)
{
Response.Status = \"301 Moved Permanently\";
Response.AddHeader(\"Location\",http://www.0574nb.cn/\");
}
</script>
PHP:

<?php
Header( \"HTTP/1.1 301 Moved Permanently\" );
Header( \"Location: http://www.0574nb.cn\" );
?>


关注宁波网站建设博客,更多精彩分享,敬请期待!
 

Tags:

很赞哦! ()

文章评论

点击排行

本站推荐

站点信息