转自: http://blog.sina.com.cn/s/blog_6c739e63010137ui.html
php手册上传错误资料:http://php.net/manual/zh/features.file-upload.errors.php
http://php.net/upload-max-filesize
Maximum number of files that can be uploaded via a single request
max_file_uploads = 20 :单个请求时,允许上传的最大文件数 ;
Maximum allowed size for uploaded files.
upload_max_filesize = 64M,允许上传你的最大文件大小 ;
; Maximum size of POST data that PHP will accept.
; Its value may be 0 to disable the limit. It is ignored if POST data reading
; is disabled through enable_post_data_reading.
post_max_size = 3M, 表单允许上传的最大文件大小,官方解释:http://php.net/post-max-size
文件上传的其他注意事项
在上传大文件时,你会有上传速度慢的感觉,当超过一定的时间,会报脚本执行超过30秒的错误,这是因为在php.ini配置文件中max_execution_time配置选项在作怪,其表示每个脚本最大允许执行时间(秒),0 表示没有限制。你可以适当调整max_execution_time的值,不推荐设定为0。