Page Rule Migration for Pro Plan with patterns

I have a page rule which takes the following pattern *.example.com/A/B/*.test.com/C/D and redirects to https://www.test.com/${3} which would be https://www.test.com/C/D.

With the page rule deprecation and that fact that the Pro Plan does not give me the ability to use regex, how should I go about solving this particular edge case? This is the last of my page rules to handle, and it is the only one that has caused me to scratch my head.

I’m a little thrown off by your pattern. I see two wildcards, but you reference $3.

Do you just want to take everything after the /A/B/ and redirect like this?

anything.example.com/A/B/new.host.com/C/Dhttps://new.host.com/C/D

Apologies, I meant to make /C/D the other asterisk. What you referenced is correct, that is my intent.
anything.example.com/A/B/new.host.com/C/Dhttps://new.host.com/C/D

I’m pretty sure you can use a length statement to snip off the beginning. I’ve seen other posts around here that use that method.

UPDATE: Found one reference: Dynamic Wildcard Redirect Rule - #2 by ncano

3 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.