在wordpress上传一个1.1M左右size的图,竟然爆http error。。。google 了一下,竟然要配置一下apache 的 mod_security 模块,但我用的是nginx啊。。。
感觉不是wordpress的问题,难道是nginx的配置问题??查看了一下error log,发现这句
client intended to send too large body: 1134408 bytes
原来如此,我以前好像配置过这个,找了一下,作出修改如下:
在location ~ \.php$ 的标签下,加一行
client_max_body_size 8m;
然后重启nginx,我一般这样重启 killall -HUP nginx,OK,上传没问题了!!