Support » Fixing WordPress » 301 Redirect Root to Subfolder – htaccess not working.

  • I just moved WP install from root directory to sub folder.

    hosted index.html simple website on the root. Sub folder has wordpress /blog.

    Now after moving wp to sub folder, the 301 redirects aren’t working for the blog post that was hosted on the root directory.

    The exact same issue am facing has been blog posted here –

    The solution given here works fine. The only issue am facing is, in the htaccess file it redirects all the files other than index.html.

    so the images folder which serves index.html also redirects to /blog.

    By adding a line of code n htaccess file can make the images folder and other folders which serves index.html make it not redirect to /blog?

    help appreciated.

Viewing 1 replies (of 1 total)
  • Options +FollowSymLinks
    RewriteEngine on
    RewriteCond %{REQUEST_URI} !^/$
    RewriteCond %{REQUEST_URI} !^/index.html$
    #Anything else you want to load directly above and below is for the blog and dynamic calls
    RewriteRule (.*)$1 [R=301,L]

    Adding this line

    RewriteCond %{REQUEST_URI} !^/images$

    after RewriteCond %{REQUEST_URI} !^/index.html$ will solve the issue?

Viewing 1 replies (of 1 total)
  • The topic ‘301 Redirect Root to Subfolder – htaccess not working.’ is closed to new replies.