我正在跑步XAMPP
并试图捕捉对我的所有请求Directory
http://localhost/api
index.php
在 - 文件夹中api
工作和服务
我不知道重写是否有效,因为所有请求都http://localhost/api/whatever
以http://localhost/dashboard
httpd.conf
Alias /api "F:/src/api"
<Directory "F:/src/api">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
Require all granted
</Directory>
.htaccess(在我的F:\src\api
文件夹中)
据我所知,这应该将所有请求重定向到,index.php
但它没有
Options -MultiViews
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L,NC,QSA]
</IfModule>
我怎样才能让我的重写工作?