如何通过URL重写规则实现301重定向

2025-04-05 01:34:24
推荐回答(1个)
回答1:

ASP:
Response.Status="301 Moved Permanently"
Response.AddHeader "Location","http://lusongsong.com/"
Response.End
PHP:
header("HTTP/1.1 301 Moved Permanently");
header("Location:http://lusongsong.com/");
exit();

301重定向代码和测试工具
国外:http://www.seoconsultants.com/tools/headers
国 内:http://www.ranknow.cn/tools/redirectcheck