How to increase upload_max_filesize on cPanel server
Recently I had to increase the upload_max_filesize value for Joomla website. It was running on the cPanel based server. You would say – “It‘s an easy task!”. Right, the upload_max_filesize can be easily changed via php.ini file.
I was going to increase my upload limits to 50MB, so I added upload_max_filesize = 50M to my php.ini file and uploaded it into public_html directory. When I tried to upload 10MB file via Joomla backend, I got the error… upload_max_filesize was still set to 2M…
While phpinfo was showing, that upload_max_filesize is set to 50M, this value was set to 2M in Joomla. To check your PHP settings in Joomla, just login to admin panel, go to General >> System information >> PHP settings.
Finally the solution was found on www.lunarforums.com. In two words, you just need to specify the correct path to your php.ini file. Open your .htaccess file and put there the following line:
Replace “/path/to/your/public_html” with path to the directory that contains your php.ini file. In my case settings was the following:
file_uploads = On
upload_max_filesize = 50M
post_max_size = 50M
Was this article helpful? Please leave a comment!