简体   繁体   中英

PHP - can't upload files bigger than 20MB

I have a problem with adding multiple files on my server. Everything works fine on smaller files (<20MB). They are uploading on the server and into my data base without any errors or problems. But when I want to add files bigger than 20MB (for example 10 files, 2,2MB each) uploading doesn't work. There is no error, just nothing is sended via _POST. I tried to change php.ini files, but it is still the same problem.
I've increased:

max_execution_time to one hour
max_file_uploads to 100 files
memory_limit to 512M
output_buffering to 30M (earlier I've turned it off)
post_max_size to 64MB
upload_max_filesize to 64M

The website is on OVH hosting, so every changes I've made in .user.ini file.
When I'm trying phpinfo() it shows values which I've changed.

Anyone knows any solution?

in your .htaccess file, this allow me to add upto 2 GB

php_value upload_max_filesize 2048M
php_value post_max_size 2048M
php_value max_execution_time 259200

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM