使用.htaccess实现301重定向
摘要:
301重定向的作用:1.规范网址;2.排除了重复页面;3.增加网址权重首页新建一个空文件.htaccess,填入重定向规则后,上传到网站根目录。用301将不带WWW的域名重定向主域名:rewriteEngine onrewriteCond %{http_host} ^abc.org[NC]rewriteRule ^(.*)$ http://www.abc.org/$1 [R=301,L]用301将绑定的其他域名重定向到主域名: 注意这个地方,有RewiteEnginee on这句,RewriteEngine onRewriteCond %{HTTP_HOST} ^其他域名.com$ [OR]R 阅读全文
posted @ 2012-06-26 14:15 mashuaimama 阅读(200) 评论(0) 推荐(0) 编辑