htmlwordpress

Browsers try to download html file instead of opening


Browsers (Chrome and Safari) Try to download this html file when opened. It is only on that link that it tries to download it. Also note that internet explorer opens it without a problem.

The one thing that I think is causing this may be wordpress or some plugin within wordpress but it seems unlikely since no wordpress is used in that page.

Contact html code


Solution

  • Likely an incorrect mime type in your .htaccess file. I suggest going into it and looking for any unwanted lines similar to the below and removing them.

    AddHandler application/ etc.
    

    and also ensure your type is set as follows:

    AddType text/html .html
    

    In order to open .htaccess in cPanel: Click File Manager and make sure to tick Show Hidden Files (dotfiles) before clicking Go. Then the .htaccess should show up the location where wp (wp-admin, wp-content, wp-includes) is installed.