1

I am mapping old Urls to new Urls using Sitecore 9.0 with SXA 1.5 - Redirect Map following this document:

https://doc.sitecore.net/sitecore_experience_accelerator/16/working_with_content/search/map_a_url_redirect

It works for direct Urls but when I do a wild-card, I get a resource unavailable.

For example, I map /Destinations/Paris to /Paris the redirect works.

But when I do the same with wild card like

OLD NEW
/Destinations/(.+) /Paris
/Destinations/(.+) $1
^/Destinations/(.+) /Paris

They are not working. Any pointers appreciated.

2 Answers 2

2

I believe there is some logic in SXA to ensure that the text is actually a regular expression.

It should start with ^ and end with $.

Try this format:

^/careers/job-opportunities(/.*)?$
1
  • Thanks that worked - Looks like it needs to start with a ^ and end with $
    – Ramani
    Commented Jul 11, 2018 at 0:08
0

You can refer this article for token implementation of redirect map using regex. https://sitecoretroubleshooting.blogspot.com/2023/08/redirection-in-sxa.html

1
  • While this link may answer the question, it is better to include the essential parts of the answer here and provide the link for reference. Link-only answers can become invalid if the linked page changes. - From Review Commented Aug 11, 2023 at 15:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.