代码如下 | 复制代码 |
location ~ ^.+\.php { root D:/workspace; fastcgi_pass bakend; fastcgi_index index.php; # 关键在这里 set $real_script_name $fastcgi_script_name; if ($fastcgi_script_name ~ "^(.+?\.php)(/.+)$") { set $real_script_name $1; set $path_info $2; } fastcgi_param SCRIPT_FILENAME $document_root$real_script_name; fastcgi_param PATH_INFO $path_info; fastcgi_param PATH_TRANSLATED $document_root$path_info; include fastcgi.conf; } |
时间: 2024-10-10 04:55:55