【发布时间】:2013-06-29 12:34:39
【问题描述】:
我在 php.ini 中设置了“upload_max_filesize=1024M”和“post_max_size=1024M”。
我通过网络浏览器上传大文件(2048M)时发现问题。
文件仍在上传,而我可以看到上传进度号,并立即在 apache 服务器日志 (/var/log/apache) 中收到 PHP 消息,如下所示:
"PHP Warning: POST Content-Length of 2147483647 bytes exceeds the limit of 1073741824 bytes"
最后上传作业失败,因为文件大小大于upload_max_filesize (2048M > 1024M)
在我知道文件大小大于upload_max_filesize 的情况下,如何尽快拒绝上传作业?
【问题讨论】:
-
hmm.. 我应该关闭是重复的还是单击谷歌? :)
标签: php file-upload php-ini