• Resolved ahoyroo

    (@ahoyroo)


    Can anyone explain why (in very simple terms, I am not very technical) I can have this page, just created this morning:
    http://www.glenmorecountryhouse.co.uk/index.html
    …but I cannot rename the file name of my actual Home Page (which doesn’t currently have a filename) to index.html?

    It is probably something to do with htaccess and Custom Permalinks but as I say I am not a techie and don’t fully understand how they work to be honest.

Viewing 2 replies - 1 through 2 (of 2 total)
  • An “index.html” used to be the way ordinary HTML-based web sites designated their home page. WordPress is database-driven, so there really isn’t an “index.html” for it; the home page is dynamically created from your theme and your database.

    You can install WordPress in a subfolder, use an index.html in your root directory as a landing page, and link to the WordPress site, but really, why would you want to do that (unless you were running multiple installs of WordPress and used the landing page as a selector-page)? Your search engine results will be much better using the WordPress site as the home page.

    Looking at the link you supplied for the index.html page, it looks like what you really might be asking is, how can I get all the people who have links to my old index.html page to go straight to my new WordPress site and update their old links?

    That’s where a redirect in your .htaccess file comes in. I would try putting the following at the top of your .htaccess file (above any redirects related to WordPress) in the root directory of your domain, or creating a new .htaccess with this in it if you don’t have one:

    RewriteEngine on
    RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.html\ HTTP/
    RewriteRule ^index\.html$ http://www.glenmorecountryhouse.co.uk/ [R=301,L]

    Then test by trying to browse to the old index.html both with and without “www” and see if it takes you to the WordPress home page.

    Thread Starter ahoyroo

    (@ahoyroo)

    Thanks very much – this .htaccess solution does exactly what I wanted it to do. Very grateful for your time and assistance.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Can index.html be used by my Home Page?’ is closed to new replies.