Apache 301转向技巧

建立.htaccess文件 //可在windows cmd下或是通过文本编辑器完成
301重定向代码如下:
[cc lang=”php”]
rewriteEngine on
rewriteCond %{http_host} ^laod.cn [NC]
rewriteRule ^(.*)$ http://www.laod.org/$1 [R=301,L]
rewriteCond %{http_host} ^www.laod.org [NC]
rewriteRule ^(.*)$ http://www.laod.org/$1 [R=301,L]
[/cc]
可以定义多条同时实现多个跳转

原创文章,作者:老D,如若转载,请注明出处:https://laod.cn/1233.html

(4)
上一篇 2015-11-25
下一篇 2015-12-04

相关推荐

发表回复

登录后才能评论