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
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Adobe Summit 2023 [19th to 23rd March, Las Vegas and Virtual] | Complete AEM Session & Lab list
SOLVED

How to get list of websites in AEM instance?

Avatar

Level 3

Hi Team,

I am using AEM 6.4.4 and I need to get list of websites exist with this path /content/*/en/brand***/website*** in backend class.How to get regular expression for the same and generate paths.

Brand and Website are for example structure.

Please help me to get this done.

Thanks,

Kiran

1 Accepted Solution

Avatar

Correct answer by
Level 3

Hi Kiran,

You need to use the JCR queries to fetch the data in the backend class , I have noy tried by myself but you can use the queries to get you the desired results with regular expression. for example - "WHERE ISDESCENDANTNODE(s,'/content/*/en/*/product')"

Query Builder API

0 Replies

Avatar

Level 4

Try to use an API to search the JCR like QueryBuilder API.

Avatar

Correct answer by
Level 3

Hi Kiran,

You need to use the JCR queries to fetch the data in the backend class , I have noy tried by myself but you can use the queries to get you the desired results with regular expression. for example - "WHERE ISDESCENDANTNODE(s,'/content/*/en/*/product')"

Query Builder API

Avatar

Level 3

I am getting list of websites. I need to get list of groups and users associated with the website.

Please help me to achieve this.

Thanks,

Kiran