猿问

怎样让nginx支持pathinfo模式?下面是我的配置文件

server {
   listen 80;

   root /var/www/html/dms/public;
   index index.php index.html index.htm index.nginx-debian.html;

   server_name www.abc.com;

   location / {

       try_files $uri $uri/ /index.php?$query_string;
   }


   location ~ \.php$ {
       include snippets/fastcgi-php.conf;
       fastcgi_pass unix:/run/php/php7.0-fpm.sock;
   }

   location ~ /\.ht {
       deny all;
   }
}
HUH函数
浏览 344回答 3
3回答

元芳怎么了

这里有个现成的,照这个写的试试看。
随时随地看视频慕课网APP
我要回答