我的知识记录

请问pbootcms网站Nginx环境伪静态配置

1、到后台配置参数中开启伪静态;

2、在nginx虚拟主机location配置中添加规则,规则如下:

location / { 	 if (!-e $request_filename){ 	    	rewrite ^/index.php(.*)$ /index.php?p=$1 last;             	rewrite ^(.*)$ /index.php?s=$1 last; 	 } }

 注意:Nginx中如果站点部署在二级目录,请对应修改重写规则, 如:二级目录为test则:rewrite ^/test/(.*)$ /test/index.php?p=$1 last;

标签:pbootcms视频-pboot cms-pbootcms商城-pbootcms免费模板-pbootcms新手入门教程-

更新时间:2025-04-10 22:34:18

上一篇:请问帝国cms后台登陆认证码修改

下一篇:请问帝国cms 批量替换字段值使用说明