.htaccess代码是
RewriteEngine off
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule ^$ public/ [L]
RewriteRule ^(.*) public/$1 [L]
</IfModule>
问题出在哪里?
我不太确定这是否是您想要做的,但请尝试这样做:
RewriteEngine Off
<IfModule mod_rewrite.c>
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteEngine On
RewriteBase /
RewriteRule ^(.*)$ public/$1 [L,QSA]
</IfModule>