Ever tried to upload an image using the flash uploader in Wordpress 2.7 and received a “HTTP error”?
The problem has something to do with mod_security, a security measure your web hosting provider has installed. Getting the flash uploader to work around mod_security requires modification of your .htaccess file which can be found in the root folder of your Wordpress installation.
Sound tricky? No problem, John Blackbourn has created a Wordpress plugin to help you out. Download the Image Upload HTTP Error Fix plugin. Be warned - I haven’t personally tested it, however it should work on all Wordpress 2.5+ installations.
Update: If you do not have a flash uploader button in the first place, you have an entirely different problem. The solution I am aware of for this issue is to reupload your Wordpress installation files much the same as you would if you were upgrading to a new version of Wordpress. You may still require this fix afterwards. If there are any other known solutions to this issue, please drop a comment. If you are getting the “HTTP error” problem, read on.
If you’d prefer to update your .htaccess file manually or the plugin doesn’t work for you here are some instructions:
1. Open your favourite FTP client and connect to your server.
2. Navigate to the root of your wordpress installation.
3. Find and copy the .htaccess file to your computer.
4. Open .htaccess in your text editor.
5. Add the following lines of code to the top of your .htaccess file:
#BEGIN Image Upload HTTP Error Fix
<IfModule mod_security.c>
<Files async-upload.php>
SecFilterEngine Off
SecFilterScanPOST Off
</Files>
</IfModule>
<IfModule security_module>
<Files async-upload.php>
SecFilterEngine Off
SecFilterScanPOST Off
</Files>
</IfModule>
<IfModule security2_module>
<Files async-upload.php>
SecFilterEngine Off
SecFilterScanPOST Off
</Files>
</IfModule>
#END Image Upload HTTP Error Fix
6. Save, and reupload to the root of your Wordpress installation overwriting the existing file.
All done, your Wordpress flash uploader will now function as intended
Related posts:
- Ultimate List Of 15 Necessary Wordpress Plugins For Any Installation In front of every great Wordpress blog, there is a...














12 Comments
thanks, worked perfectly
ahh cool i was wondering about that
Glad I could be of assistance ;).
thanks!!..finaly got solution for this
Did not work for me, I’m running 2.6.2.
The above code appears to be for 2.7 only. Did you try the plugin instead?
I tried both ways on 2.6.2 and upgraded to WP 2.7 with no luck on either the automatic nor manual way. I get so tired at Wordpress…
Screenshot:
http://www.flickr.com/photos/steffo5/3196699848/
Is there anything I could be doing wrong, emptying cache, log out or whatever…
http://wordpress.org/support/topic/164999
Take a look there.
I’m using W2.7 but doen’t work. Also I try to clean the browser cache but nothing, still with the HTTP Error
Any idea?
If you’ve tried both the .htaccess fix and also tried re-uploading all your WordPress files (make sure you only upload the files required for a WordPress Upgrade), and you’ve visited the link in my previous comment, then I suggest opening a thread on http://wordpress.org/support/.
This great! Thanks so much!