13 lines
431 B
ApacheConf
13 lines
431 B
ApacheConf
RewriteEngine on
|
||
|
||
# 将API请求重定向到source/public目录
|
||
RewriteCond %{REQUEST_FILENAME} !-f
|
||
RewriteCond %{REQUEST_FILENAME} !-d
|
||
RewriteRule ^api/(.*)$ source/public/index.php/$1 [L]
|
||
|
||
# 将其他请求也重定向到source/public目录,除非文件存在
|
||
RewriteCond %{REQUEST_FILENAME} !-f
|
||
RewriteCond %{REQUEST_FILENAME} !-d
|
||
RewriteCond %{REQUEST_URI} !^/source/public/
|
||
RewriteRule ^(.*)$ source/public/index.php/$1 [L]
|