问题描述
我正在尝试通过邮递员将大图像上传到服务器(二进制文件上传),它对于2 MB及以下的文件可以正常工作,但是对于大于2 MB的文件,上传失败
I am trying to upload large images to server (binary file upload) via postman, it works fine for files sized 2 MB and below, however for files > 2 MB the upload fails
我设置了 php.ini
upload_max_filesize = 100Mpost_max_size = 100M
upload_max_filesize = 100Mpost_max_size = 100M
和
nginx /etc/nginx/nginx.conf
client_body_buffer_size 100M;client_max_body_size 100M;
client_body_buffer_size 100M;client_max_body_size 100M;
但是它不起作用
我尝试使用 plupload 软件包进行块上传,但是它对于大于2 MB的文件也不起作用
I tried plupload package for chunk upload but it also doesn't work for files > 2 MB
有什么想法可以在laravel中上传大图像吗?
Any ideas how to upload large images in laravel ?
推荐答案
它不起作用,因为设置了错误的php.ini文件在laravel dd(phpinfo())
上执行此操作,并在
It's doen't work because you set the wrong php.ini filedo this on laravel dd(phpinfo())
and look the right php.ini use by laravel in the value
这篇关于Laravel上传大图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!