Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

AEM Sling Vanity, Add prefix path to the stored value

Avatar

Avatar
Level 1
karthikb1706130
Level 1

Likes

0 likes

Total Posts

2 posts

Correct Reply

0 solutions
View profile

Avatar
Level 1
karthikb1706130
Level 1

Likes

0 likes

Total Posts

2 posts

Correct Reply

0 solutions
View profile
karthikb1706130
Level 1

02-02-2021

I have two sites for example

/content

------siteA

------siteB

whenever an author authors the sling vanity property for a particular page under site A, I want to append /siteA/ as a prefix to the value stored, similarly when an author authors vanity property under siteB, I need to append /siteB/ as a prefix to the value stored.
I came to know what we can achieve it using vanity-root tenant conf but could not find any documentation anywhere. 

Any suggestions on how to achieve this.

 

Thanks in Advance!!

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Give Back
Level 4
Sanket_Kumbharkhane
Level 4

Likes

46 likes

Total Posts

50 posts

Correct Reply

20 solutions
Top badges earned
Give Back
Boost 5
Boost 3
Boost 25
Boost 10
View profile

Avatar
Give Back
Level 4
Sanket_Kumbharkhane
Level 4

Likes

46 likes

Total Posts

50 posts

Correct Reply

20 solutions
Top badges earned
Give Back
Boost 5
Boost 3
Boost 25
Boost 10
View profile
Sanket_Kumbharkhane
Level 4

02-02-2021

Hi @karthikb1706130,

You can refer to the steps needed to add and configure the Vanity Path Rewrite Mapper,

please visit https://adobe-consulting-services.github.io/acs-aem-commons/features/vanity-path-rewrite-mapper/inde...

 

Or

You can write a helper class using wcmuse or sling model and add it to your base template. So, whenever the author edits the vanity Url and saves the page, the request goes to the helper class. In helper class, you can read the value of vanity Url, append Sitename as prefix and write it back. 

Note: This is strictly for Author environment

Answers (0)