青衣 发表于 2021-8-23 12:48:57

nginx 伪静态化rewrite规则

代码如下:


location / {

###以下为PHPCMS 伪静态化rewrite规则

rewrite ^(.*)show-(+)-(+)\.html$ $1/show.php?itemid=$2&page=$3;

rewrite ^(.*)list-(+)-(+)\.html$ $1/list.php?catid=$2&page=$3;

rewrite ^(.*)show-(+)\.html$ $1/show.php?specialid=$2;



####以下为PHPWind 伪静态化rewrite规则

rewrite ^(.*)-htm-(.*)$ $1.php?$2 last;

rewrite ^(.*)/simple/(+\.html)$ $1/simple/index.php?$2 last;

}
本文出自 “linux进阶屋” 博客
文档来源:http://www.zzvips.com/article/16118.html
页: [1]
查看完整版本: nginx 伪静态化rewrite规则