1
到现在,我有我的API是根,为exmple前值:https://api.example.com
nginx的设置URL重写规则
,因为我使用CI,我需要每路径改写为指数,像这样:
location/{
try_files $uri $uri/ /index.php?q=$uri&$args
}
现在,我搬到版本的API,所以每个版本都是在一个子目录,例如:https://api.example.com/0.0.1/
我怎样才能改变我的规则,以适应新的模式? (如果文件夹,然后东西,使用该文件夹的索引)