Support » Fixing WordPress » redirect /oldStaticDir/index.html to /newWPDirectory

Viewing 4 replies - 1 through 4 (of 4 total)
  • i know this is a tough problem, right?

    One thing I probably should have mentioned.

    I tried to create multiple index.html files under the categories. But quickly realized that wordpress won’t allow me to have pretty permalinks using the same post name even if they are in the same category.

    This might be an advanced topic.

    So wordpress was indeed functioning as it should. apparently my RewriteCond was too verbose and wordpress rescued me by gracefully serving up the closest match it could find for the index.html I was calling.

    Here is the working rewrite rule. of course substitute http://www.domain.com

    RewriteCond %{THE_REQUEST} ^([^/]+/)*index\.html\ HTTP/
    RewriteCond %{THE_REQUEST} ^.*/index\.html
    RewriteRule ^(([^/]+/)*)index.html$ http://www.domain.com/$1 [R=301,L]

    resolved

    lol ooops

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘redirect /oldStaticDir/index.html to /newWPDirectory’ is closed to new replies.