htmlwordpress

Open .html file in WordPress website


I have WordPress website in which I uploaded "popup-menu.html" file which is in .html format.

When I visit url "http://testproject.co/projects2015/prismic_new/wordpress/popup-menu.html" is shows 404 error.

I uploaded HTML file into my theme directory. I think I should have upload it to my root directory, but will that work?

I am curious why I am not able to see that file. There is something I am ignoring or don't know about WordPress. Please help me with that.


Solution

  • If you need to have a static , non WordPress file on your server you can have it on the root directory , just as another file, and can easily access it from the URL . WordPress will not interfere with that url.

    WordPress .htaccess will not try to implement its redirect rules on any FILE or FOLDER which exists on main root folder or anywhere.

    So if e.g. you need /static.html , you can safely upload it on your root folder with the same name and can access from your browser, WordPress will have nothing to do with it.

    You do not need to put it in themes folder as you have done in the start.