Solutions Log (2014-07)

2014-07-10: 配置nginx重写规则,检查跟文档一致无拼写错误,但仍然提示:nginx: [emerg] unknown directive "if($query_string" in /etc/nginx.conf.d/default.conf。查资料显示:是拼写格式的问题,正确的格式(以#号代替空格)是:if#($query_string !~ ".*[\;'\<\>.*]"#) { deny all; }.参考网址:http://wiki.nginx.org/HttpRewriteModule#if和http://www.iigrowing.cn/nginx-zhong-zhong-xie-rewrite-de-yu-fa-cuo-wu-emerg-unknown-directive-if-host.html

你可能感兴趣的:(log,solution)