location / {
#单入口文件配置
try_files $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
# 匹配php后缀的配置
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_pass 127.0.0.1:9000;
try_files $uri =404;
}
location ~* /\. {
# 匹配http://servername/.?
deny all;
}
老师,你好,我已经中文注释了,前面2个location,但请看后面的一个location,他是正则匹配,"."表示任意一个字符。我想他们匹配的是http://servername/.,但是我觉得我的理解是错误的,请指正。谢谢