This happens when your PHP Upload Max Filesize (upload_max_filesize) set in your php.ini file is smaller than the file size of Apress Theme or the file size of the image that you are trying to upload.
At the time of writing, the file size of Apress Theme (zip file) is 46.2M.
Look into your System Informations for the value of PHP Upload Max Filesize, you will need to increase it to a higher and healthier value.
Solutions #
Contact your Hosting Company #
Yes, this is the most prefer way. Contact your hosting company and show them a screenshot of your error or write to them the error message.
Ask them to assist in increasing the following values, until you are able to install your Apress Theme or upload your image.
Your hosting company may have restrictions on these values.
memory_limit upload_max_size post_max_size upload_max_filesize max_execution_time max_input_time
Preferably to the following values.
memory_limit = 256M upload_max_size = 64M post_max_size = 64M upload_max_filesize = 64M max_execution_time = 300 max_input_time = 1000
Editing php.ini File #
The php.ini file is the default PHP configuration file. Most of the Shared Hosting Company does not allow access to this file. If you are certain that you have access to php.ini file on your server, you may proceed with the following steps.
- Access it using your FTP program. (how to do use a FTP software with WordPress ?)
- Backup a copy of this file before attempting to edit it.
- Preferably, edit them to the following values.
memory_limit = 256M upload_max_size = 64M post_max_size = 64M upload_max_filesize = 64M max_execution_time = 300 max_input_time = 1000
Or create php.ini file in root and placed the above code. This also works for you.
Amending your wp-config.php #
You can try adding a memory define to WordPress in it’s wp-config.php, but this will not work, if your defined memory exceeds your actual server allocated memory.
- Use your ftp program and navigate to your WordPress root directory.
- Find your wp-config.php and download a copy to your computer as backup.
- Open up wp-config.php using your plain text editor or code editor.
- Insert the following code at the end of the file.
define('WP_MEMORY_LIMIT', '256M');
- Save and upload back your wp-config.php to your WordPress installation.
- Clear your browser cache and re-load your website.
- If you are still experiencing error, you should contact your web hosting company for assistance.
That’s all for this documentation. Hope it helps!