I am facing issue were long urls are not getting shortened on page. we have used page.getPath method to place page url in href. But it is showing entire path starting from /content intead of short urls.
Views
Replies
Total Likes
Hi,
You can try reverse mapping like below:
Sling Reverse Mapping ignoring parameters and special characters like #
Views
Replies
Total Likes
didnt helped. Tested with above changes.
Views
Replies
Total Likes
Can you show your etc reverse mapping, I tested same for we-retail it is working.
Views
Replies
Total Likes
Views
Replies
Total Likes
After above changes still giving entire path (/content/we-retail/us/en) on page.getpath
Views
Replies
Total Likes
Can you make changes like below:
4 | sling:internalRedirect | String | /content/we-retail/(.*).html |
5 | sling:match | String | localhost.4502/$1.html | f |
Above will remove /content/we-retail from all links which starts with /content/we-retail
In your config it seems you did reverse mapping if there is a link like <a href="https://forums.adobe.com/content/we-retail/">Link</a> will be render like <a href="https://forums.adobe.com/">Link</a>
Views
Replies
Total Likes
Thanks this is working fine on my local vanilla instance. But on higher env. with my application code deployed it is not working. Any pointers which might be stopping this to work?
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies