First, do not edit php.ini, instead add a file to
called something like php_ini_local.ini, for instance. Place parameters you would like to customize like upload_max_filesize in there, and they will take precedence over those in the php.ini file(s). And this way php.ini will in future also upgrade gracefully to newer versions without manual intervention.
To test parameter changes (before and after) the simple way, use PHP CLI in a terminal:
# php -a Ctrl-d
Add this line to the VirtualHost:
php_value error_reporting 0
(Note: php.ini changes apply to *all* PHP apps on the server.)
If you are getting the error:
Upload larger than maximum POST size (post_max_size variable in .htaccess or php.ini)
There is no simple one parameter solution. I found some good posts
I made the following changes in /etc/php5/apache2/php.ini:
post_max_size = 300M
upload_max_filesize = 300M
max_execution_time = 3600
max_input_time = 3600
which should present a maximum file upload limit of 300M and a timeout of one hour.