Sometimes while working with images in wordpress we are getting “http error”. This is an unreadable http error which can puzzle many people. In this article we are going to explain that how can we fix this error. Many times the reason may be that we are trying to upload large image like 2000 x 2000 pixels. If you are getting this error uploading large images on server then it may be the main reason you can get HTTP error. It all depends of server allotted resources.

http.png

Now the question arise how to solve this error so here are some points through which you can check the exact problem:

1. Increase PHP Memory : by default we can upload 2MB image in wordpress but if you need to upload large images then it is must to increase the PHP memory. Here are various ways to increase PHP Memory.

· You can easily increase the upload file size by adding code in your wp-config file. Buy it is must to have enough memory in your package. You have to add following code :

Code:
 define( 'WP_MEMORY_LIMIT', '256M' );
· You can also add .htaccess file in your file manager with following code, so that it will increase the size of upload image file.

Code:
php_value memory_limit 256M
· You can also increase the upload image file by adding php.ini file on your web server. In this file you have to check for the code or increase it according to your image size.

· If you are not able to do all the above options then you have to contact your hosting provider and ask them to increase your PHP memory limit.

2. Decrease your images size before uploading: You can easily decrease the size of your image by using paint. It is the easiest and simplest method to reduce the size of your image.

3. ModSecurity : if your server have mod security then sometimes it also cause the problem while uploading files or images.

How you can check it?

· You can disable the modsecurity from cPanel provided by your hosting provider.

· There is also another method, you have to create .htaccess file in wp-admin directory with and add following code to disable mod security temporary.

Code:
<IfModule mod_security.c>

SecFilterEngine Off

SecFilterScanPOST Off

</IfModule>
NOTE: After checking you have to turn modsecurity on so that your website will be safe from malicious attack.

4. Plugin conflict: if all the above methods do not work in your case then it may be possible that any plugin is causing the issue. To check this disable the installed plugin one by one so that you can check which plugin is causing the issue. And at last clear your browser cache and try again. May be this article is helpful for you in solving this issue.
Author
bhawanisingh
Views
3,984
First release
Last update
Rating
0.00 star(s) 0 ratings
Top