1. public下的.htaccess /WEB/public/.htaccess
<IfModule mod_rewrite.c> Options +FollowSymlinks -Multiviews RewriteEngine on RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^(.*)$ index.php?s=$1 [QSA,PT,L] </IfModule>
据说是万能的伪静态规则 我用了确实好用
2.根目录下的 /WEB/.htaccess
RewriteEngine on RewriteCond %{REQUEST_URI} !^/public/ RewriteRule ^(.*)$ /public/$1 [L]
指定到 访问public下
完成!