i’m trying to add redirections for all paths except parent path, i tried the below redirect rules in _redirects file but it doesn’t work.
/media-center/* https://www.subdomain.com/:splat 301 (works but it overwrites “parent don’t redirect” rules so parent is also redirecting)
/media-center/experts/* /index.html 200! (doesn’t work - redirects to subdomain)
/media-center/index.html /index.html 200! (doesn’t work - redirects to subdomain)
expected results:
All /media-center/* pages should redirect to subdomain
Path with /media-center/experts/* should not redirect
Parent path of /media-center/* i’e (/media-center/index.html) should not redirect
Not sure how “force” flag will work when there is 2 different redirect behavior for parent and children path.
@SamO i have gone through that documentation previously, it is indeed helpful, but nothing is mentioned about the type of answer i’m looking for.
i have a simple requirement, i’m using gatsbyjs framework, where the pages are generated dynamically, i just want to achieve the following, please let me know if it’s possible using netlify redirects.