Page Rule URL matching


#1

We recently moved our wordpress blog and also changed the URL structure. And so we need to use Page Rule feature of CloudFlare because with the new system we no longer have access to the htaccess file. Here is what we need:

Forward this url structure: https://www.domain-name.com/2012/09/all-the-best
to
https://blog.domain-name.com/blog/all-the-best

Please note that I only want the above to be done when the url structure is /(4 digits)/(2 digits)/*.

I have tried /* /* /* and forwarded it to https://blog.domain-name.com/blog/$3. But this works for all the url structures and not just if it had /(4 digits)/(2 digits)/*

Thanks


#2

Yeah, the Cloudflare pattern matching is pretty limited (well, just these wildcards not regex). I don’t think you’ll be able to do what you want but you could at least try /2* /* /* (as presumably all your blog post years start with a ‘2’) to tighten up the matching somewhat.