• I get a HTTP error when uploading a new file with .docx extension, it doesn’t happen with any other file formats. And after I get the error, the website goes down for some minutes (see screenshot here >> https://imgur.com/a/xP7Gq).

    I am on a shared hosting with GoDaddy. So far, I tried all these with no luck:

    * Deactivated all the plugins and uploaded a .docx file, same result
    * Increased PHP memory through php.ini and asked GoDaddy to increase it, currently I am allowed 32MB.
    * I modified .htaccess, I tried these:
    1 – <IfModule mod_security.c>
    SecFilterEngine Off
    SecFilterScanPOST Off
    </IfModule>
    2 – # Exclude the file upload and WP CRON scripts from authentication
    <FilesMatch “(async-upload\.php|wp-cron\.php|xmlrpc\.php)$”>
    Satisfy Any
    Order allow,deny
    Allow from all
    Deny from none
    </FilesMatch>
    3 – AddType x-mapp-php5 .php (it give a 500 internal error)
    I really don’t know what these do with .htacess, but I found it on internet.
    * I changed folder permissions to 755 and even to 777
    * and I did a lot of other stuff which didn’t work.

    I would appreciate your help.
    My WordPress site is installed inside a folder, and I have a subdomain pointing to that.

    Thanks,

Viewing 15 replies - 1 through 15 (of 24 total)
  • Thread Starter samimhakim87

    (@samimhakim87)

    Just to mention, I also tried to disable FastCGI, but it didn’t work.
    I tried some other plugins like File Manager, and some uploader plugins, but it doesn’t work. File manager say “Connection Aborted” when I upload .docx file. I also enable its MIME type, but no luck.

    Have you tried:
    -switching to the default theme to rule out any theme-specific problems.

    Thread Starter samimhakim87

    (@samimhakim87)

    Thanks for reply kmessinger. Yes, I also did that, but still the same problem. One thing else I should mention, is that when I rename a file extension to docx (for example I rename Book1.xlsx to Book1.docx), it accepts the file, but when the file is saved by Microsoft Word in docx format, it gives HTTP error. There is no problem saving the file in .doc format.

    Thread Starter samimhakim87

    (@samimhakim87)

    Also when I rename a docx extension to another file format (for example I rename test.docx to test.doc), it doesn’t accept the file and when the upload reaches to 100% it gives the same HTTP error.

    Are you using add media or a plugin?

    Thread Starter samimhakim87

    (@samimhakim87)

    I am using add media.

    I get almost the same result. I get the file name and that is all. There are some plugins for importing Word files or you can save them as a PDF to import them.

    Word uses its own markup language which does not convert cleanly to HTML. It has been problematic for years.

    Thread Starter samimhakim87

    (@samimhakim87)

    Ok, I will search for such plugins, but I really want the files to be in word format, as it is template for clients.
    I don’t want word files to be embedded on a page, I only want them to be uploaded on the upload folder and then I can make link to them on a page.

    Oh, then don’t add media. Upload the file using ftp or the file manager provided by your host and then just add the link. A docx is not really media.

    Thread Starter samimhakim87

    (@samimhakim87)

    Yah, that would be easy for me. But my client is not that much professional, he just clicks on “Insert Media” button on the posts and add the document. In fact, I tried to add some FTP plugins inside WordPress, but again the same result, it says “connection aborted”. I wonder why this happens with this site only, I have so many other wordpress sites, none of them has the same problem.

    I am still looking into this. Another reports that he gets a link.

    I cannot duplicate your error. When importing a docx file I just get a link while it should be the document. Would you send me a link to the file you are uploading? You can put it on https://pastebin.com/

    Thread Starter samimhakim87

    (@samimhakim87)

    Hi, thank you for your work on this. I just found, it is Godaddy’s issue with their shared hosting plan on Linux platform. They became more agressive on apache mod_security2 module. .htaccess directives are disabled in mod_security2, so we cannot do anything from our side.

    The only solution is to use FTP.

    That sounds like over-kill to me. I will run this by some others.

    Ok. I haven’t used word in so long I had forgotten things I once knew!

    Add media is not for text files as such. PDF files are ok but for Word you should just try to cut and paste. That hopefully will change the Word mark-up to WordPress and standard html. If not you can paste as text and then reformat but the former should work.

    About GD. If they are truly disabling htaccess then a lot of people are in trouble. I think you may have talked to a new person.

    Hopefully this will resolve the problem.

Viewing 15 replies - 1 through 15 (of 24 total)
  • The topic ‘HTTP error on uploading only .docx files’ is closed to new replies.