标签:
1. Apache模块 开启rewrite
2..htaccess文件中
<IfModule mod_rewrite.c> Options +FollowSymlinks RewriteEngine On RewriteCond %{HTTP_HOST} ^qdaikuan.cn$ RewriteCond %{HTTP_HOST} ^qdaiwang.com$ RewriteCond %{HTTP_HOST} ^www.qdaikuan.cn$ RewriteCond %{HTTP_HOST} !^$ RewriteRule ^(.*)$ http://www.qdaiwang.com/$1 [R=301,L] RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L] </IfModule>
标签:
原文地址:http://www.cnblogs.com/siichen/p/5569740.html