thinkcmf5宝塔liunx版Nginx环境开启伪静态步骤。

1、绑定网站运行目录、

宝塔环境安装thinkcmf5 开启rewrite伪静态方法

 

2、填写伪静态规则:

location / {
        index  index.php index.html index.htm;
         if (!-e $request_filename)
         {
            rewrite ^/(.*)$ /index.php?s=$1;
         }
    }
location /api/ {
        index  index.php index.html index.htm;
         if (!-e $request_filename)
         {
            rewrite ^/api/(.*)$ /api/index.php?s=$1;
         }
    }
location ~* \/upload\/.+\.(html|php)$ {
return 404;
}
location ~* ^\/plugins\/.+\.(html|php)$ {
return 404;
}
location ~* \/themes\/.+\.(html|php)$ {
return 404;
}

 

宝塔环境安装thinkcmf5 开启rewrite伪静态方法

3、保存,OK!

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-11-07
  • 2022-12-23
  • 2022-12-23
  • 2021-09-20
  • 2021-11-16
  • 2021-07-06
猜你喜欢
  • 2021-06-13
  • 2022-12-23
  • 2021-08-25
  • 2022-12-23
  • 2021-10-12
  • 2022-12-23
相关资源
相似解决方案