I'm new to AEM, I need to suppress content path in the URL, for example :this link as has to redirect from https://www.act.com/content/odc/odc/un/en.html to https://www.act.com/un
In author, i configured /content/odc/odc/un/en.html this page for a hyperlink text component, when i replicate it and clicked the hyperlink test it is going https://www.act.com/content/odc/odc/un/en.html but i need https://www.act.com/un to be shown to the end customers.
Can anyone help me on this. Please guide me with steps to proceed on this.
Thanks in advance
You have to configure at
2. Link Rewrite to remove /en.html
3. mapping at apache httpd server when request comes to AEM
Mapping and reverse mapping at /etc/map
Hi @karthikfordreal,Try using etc/map in publish mode for internal redirects, it's explained in Internal Redirects
Updating the content/resource path to URL/shortened URL is called forward mapping. This can be handled by using OSGI config named - Apache Sling Resource Resolver Factory.
Description on "URL mappings" property helps understand the significance and syntax
Try this in your local publish environment first and then next higher environments.
Below sample entry for reference:
This lets the we retail page - http://localhost:4503/content/we-retail/us/en/equipment.html to be accessed as http://localhost:4503/equipment.html
Links as part of anchor tag will also be updated to shortened path. (have used ":" for two way mapping)
Below blog post provides a clear understanding on mapping.