对应站点设置中,可修改访问网站的目录,修改nginx对应站点配置文件
新增下面代码,即可完成重写路由,增加index.php
location / {
if (!-e $request_filename) {
rewrite ^(.*)$ /index.php?s=$1 last;
break;
}
}
对应站点设置中,可修改访问网站的目录,修改nginx对应站点配置文件
新增下面代码,即可完成重写路由,增加index.php
location / {
if (!-e $request_filename) {
rewrite ^(.*)$ /index.php?s=$1 last;
break;
}
}