Question

I am developing php applications on Ubuntu 13.04 and when i am trying to change the upload_max_filesize setting:

$ sudo gedit /etc/php5/apache2/php.ini

and restart apache the values do not change in my phpinfo() they stay at the default values

This is the path mentioned in the phpinfo:

Loaded Configuration File /etc/php5/apache2/php.ini

Was it helpful?

Solution 2

Try to check if there is any syntax error in your php.ini, if there is any, it will not take the changes.

also make sure that your php.ini is writable

OTHER TIPS

Those values can be read from more than one location. You only show one location (and yes there is a phpinfo showing only one location but there are other elements in phpinfo hinting additional ini locations and to tell you the truth: the phpinfo does not show all inis).

So actually this depends on your configuration (which can greatly differ as you've got an open system) and the only thing we can say for sure is that you

  • a) edited the wrong file -or -
  • b) made a mistake while editing the right file.

To fix your issue, edit the right file.

To find the right file, learn about your systems PHP configuration.

To learn about your systems PHP configuration, start removing the ini and see what happens.

To learn about how it works in general - not specific to your system - you can easily consult the PHP manual:

Or if you are on Linux (same will apply for windows, just different path), check the error log file with the command like this:

$ tail -n 100 /var/log/apache2/error.log

after restarting apache server

This will show you the line of the error and its cause in case of the syntax error in php.ini.

Check also "Scan this dir for additional .ini files" and "Additional .ini files parsed"

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top