Vo Danh Vo Danh -4 years ago 386
PHP Question

php 7 php.ini upload_max_filesize not working

I have read many solutions on internet , but still cannot change

value (
always = 2M )

here is my loaded

Configuration File (php.ini) Path /etc/php/7.0/apache2
Loaded Configuration File /etc/php/7.0/apache2/php.ini
Scan this dir for additional .ini files /etc/php/7.0/apache2/conf.d
upload_max_filesize 2M 2M
post_max_size 8M 8M

here is my edited

; http://php.net/post-max-size
post_max_size = 86M
; http://php.net/upload-max-filesize
upload_max_filesize = 40M

im using ubuntu 14.04,apache2,php7.0
(I have reset apache2 many time after each change in php.ini )

Answer Source

i fingured out !

in my loaded php.ini config , my error_reporting values is E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED-> this is wrong!, so i changed it to

error_reporting: E_ALL and then restart apache2 server, now everything working fine !

so please note : if php.ini have any error , it will use default value (which means upload_max_filesize always 2M )

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download