server {
listen 80;
listen [::]:80;
server_name domain.com;
root /var/www/html/try;
index index.html index.php;
location / {
try_files $uri $uri/ /package/mhshohel5/index.php?$args;
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
include fastcgi_params;
fastcgi_pass unix:/run/php/php7.0-fpm.sock;
fastcgi_param SCRIPT_FILENAME /var/www/html/try$fastcgi_script_name;
}
}
上面的代码一切正常,我想动态更改try_files,就像
一样try_files $uri $uri/ /package/mhshohel5/index.php?$args;
要
try_files $uri $uri/ /package/*/index.php?$args;
任何帮助都会很明显。