How To Fix HTTP Error Code When Uploading Media

Our gallery plugin creates a few extra thumbnails, which makes the uploading process take a little bit longer. Maybe by a few seconds. Not much.

However, for some servers, this might be too much, and the server might bail during the thumbnail generation process, resulting in an HTTP Error Code. You can fix this in two ways.

You can disable some or all of the different image sizes that are generated. If you do this, you will just need to make sure you upload images in the correct size you want to display in your gallery.

Screen Shot 2016-05-18 at 11.55.36 AM

Or you can increase your max execution time on your server. You can do this in a few ways.

Update your .htaccess file.

<IfModule mod_php5.c>
php_value max_execution_time 300
</IfModule>

Or, update your wp-config.php file.

ini_set('max_execution_time', 300); //300 seconds = 5 minutes

Or, you can ask your web host to do it for you.

Just to be safe, you might also increase you memory usage, to make sure the problem isn’t because your server is running out of memory.

http://knowledgebase.angiemakes.com/memory-exhausted-in-wordpress/

Another thing to consider are the size of the images your are uploading. If you are uploading very large images, that is more work when creating thumbnails. You might try resizing your images to 1600×1600 pixels before you upload your images. You can also use a plugin to auto resize large images.

https://wordpress.org/plugins/imsanity/