RewriteEngine On RewriteCond %{REQUEST_FILENAME} -f [OR] RewriteCond %{REQUEST_FILENAME} -d [OR] RewriteCond %{REQUEST_FILENAME} -l RewriteRule . - [NC,L] RewriteRule . index.php [NC,L]
Nginx
location / { index index.php index.html index.htm; if ($request_uri ~ (.+?\.php)(|/.+)$) { break; } if (!-e $request_filename) { rewrite ^/(.*)$ /index.php/$1 last; } } location ~ ^/shopadmin { rewrite ^/(.*)$ /index.php/$1 last; break; }
时间: 2024-10-05 12:46:13