• Hello!

    I’ve tried quote a few things to get what seems like a super simple problem to work, but it always ends up duplicating my regexes and causing a redirection loop.

    This is what I need to do:

    http://www.mywebsite.com/tag/(any text)

    Redirects to:

    http://www.mywebsite.com/blog/tag/(the same text from above)

    I can sort of get it to work, but it usually causes the redirection to be /blog/blog/blog/blog/……/tag/seo//////////////

    Or, some variation of that repetition.

    I’ve update the permalink settings to have the /blog/ directory in the URL before all blog pages. This applies to tags. However, for some reason, webmaster tools has indexed the /tag/ without the /blog/ causing quite a few broken URLs. I guess I could force remove them, but I’d rather do it this way as there are other links.

    If this is not possible with regex, or there is a better solution, I would appreciate it!

    http://wordpress.org/plugins/redirection/

  • The topic ‘Regex to Insert a Directory into URL’ is closed to new replies.