RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ api/index.php [QSA,L]
我拿起了Slim microframework的样本.htaccess
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [QSA,L]
并在index.php之前添加api
,现在我的应用程序无效。为什么呢?
答案 0 :(得分:0)
如果您确定在api文件夹中有index.php,请尝试将其更改为
RewriteRule ^ api\/index.php [QSA,L]