[英]What is the maximum file upload size in PHP 5?
Whta is the maximum file upload size in PHP 5? PHP 5中最大文件上传大小是多少? I am uploading a file of 6MB and get error 1. Thanks.
我正在上传6MB的文件,并收到错误1。谢谢。
它由您的php.ini中的upload_max_filesize
确定。
check your php.ini
: upload_max_filesize
检查您的
php.ini
: upload_max_filesize
That might help you :-) 这可能对您有帮助:-)
默认值为2 MB,但是您可以在php.ini中更改upload_max_filesize
The above missed one setting: post_max_size in php.ini .From php doc: "To upload large files, this value [*post_max_size*] must be larger than upload_max_filesize. 上面错过了一个设置:php.ini中的post_max_size。来自php doc:“要上传大文件,此值[* post_max_size *]必须大于upload_max_filesize。
If memory limit is enabled by your configure script, *memory_limit* also affects file uploading. 如果您的配置脚本启用了内存限制,则* memory_limit *也将影响文件上传。 Generally speaking, memory_limit should be larger than post_max_size.
一般而言,memory_limit应该大于post_max_size。 "
“
If you need to see what it is set to on your specific server, create a new file with this: 如果需要查看特定服务器上的设置,请使用以下命令创建一个新文件:
<?php echo phpinfo();
Then access it using your browser. 然后使用浏览器访问它。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.