0

I'm trying to setup some 301 redirects on WPengine using regex and I'm having trouble getting things working.

For pages that do not have the first part of the URL matching, I'm able to setup things up using the below:

  • Source: ^/abc/123/
  • Destination: ^/def/

However, when I set this up using the Old/New URL listeded above, this creates a circular reference so it does not work.

I'm trying to figure out how to create a regex expression that tells does not redirect the URL for /abc to itself, creating a circular direction.

The documentation from WPengine for this is here: https://wpengine.com/support/regex/

I've tried a bunch of different things and can't quite figure this one out.

Any help would be greatly appreciated...thank you!

1 Answer 1

0

Figured it out - adding the solution for anybody who may need it in the future!

  • Source: ^/abc/(.+)
  • Destination: ^/abc/

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .