• 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 – http://john.do/301-sub-folder/

    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)
  • Thread Starter Srivathsan G.K

    (@dangerdiabolick)

    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 (.*) http://www.myai.org/blog/$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.