-2

Here is my phpinfo()

https://devmail.equidesk.com/phpinfo.php

I can't upload more than 2MB file by php. I increased upload limit in php.ini but it's not working.

Ridwanul Hafiz
  • 181
  • 1
  • 1
  • 11

3 Answers3

1

see this: Change the maximum upload file size

you should change php.ini

upload_max_filesize = 10M

post_max_size = 10M

And if you use nginx, should change nginx.conf file

like this.

server {
    client_max_body_size 10M;

    //other lines...
}

If you changed server configurations, you should restart fpm and nginx.

sudo service nginx restart
sudo service php5-fpm restart
soredive
  • 795
  • 1
  • 9
  • 25
0

Value of your upload_max_filesize attribute is 2M. Thats why you are unable to upload more than 2M.

You need to increase size of upload_max_filesize in php.ini file. After that you will be able to upload large file.

You can change it to 128M or 256M whatever you want depends upon size of your upload file.

akshaypjoshi
  • 1,245
  • 1
  • 15
  • 24
0

upload_max_filesize in phpinfo still showing 2M

Change this and restart server

post_max_size = 250M 
upload_max_filesize = 250M 
max_execution_time = 5000
max_input_time = 5000  
memory_limit = 1000M
Rp9
  • 1,955
  • 2
  • 23
  • 31