Home > php教程 > php手册 > PHP上传文件时文件过大$_FILES为空的解决方法

PHP上传文件时文件过大$_FILES为空的解决方法

WBOY
Release: 2016-06-06 20:26:17
Original
1597 people have browsed it

发现一张gif图片上传失败 size为0,实际大小为4.66M,下面为大家介绍下PHP上传文件时文件过大的解决方法

在做图片上传的时候突然发现一张gif图片上传失败 size为0,,实际大小为4.66M。上传小文件时可以,传大文件就不行,看了下PHP.INI里面upload_max_filesize = 2M, 问题就出在这了,修改其值

复制代码 代码如下:


; Maximum allowed size for uploaded files.
upload_max_filesize = 20M


重启了下nginx问题解决。
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template