Expand my Community achievements bar.

How to search and get list of all pages of a given template in AEM? | AEM Community Blog Seeding

Avatar

Administrator

3/19/21

BlogImage.jpg

How to search and get list of all pages of a given template in AEM? by rashid jorvee blog

Abstract

How to search and get list of all pages of a given template in AEM?
Adobe experience manager is a powerful content management tool that provides ample options to explore and manage the content. In this post, we are going to see how to search and get all the pages from AEM which are created using a given template.

The detail required to execute this process.
Project path: Path of the directory where we would want to search the pages. e.g. /content/sample/en/en_us

Template path: Path of template. e.g. /apps/sample/templates/press

Now we have prerequisite handy with us, let's move to the execution.

Step 1: Go to the below mention URL. Adjust the domain according to your domain name.

http://localhost:4502/libs/cq/search/content/querydebug.html

Step 2: Put the following query in the "Query Builder Debugger" section

type=cq:Page

path=/content/sample/en/en_us

1_property=jcr:content/cq:template

1_property.value=/apps/sample/templates/press

p.limit=500

In the above query; type cq:Page will include the nodes that have type cq:Page. Other than that nodes will get excluded from the script. after that path under that, we want to search the pages. Then after the name of the property and property value that will be a path of the template for which we are looking.

Read Full Blog

How to search and get list of all pages of a given template in AEM?

Q&A

Please use this thread to ask the related questions.

2 Comments

Avatar

Level 4

7/26/21

We can also simply use ACS Commons Page Report feature.

Avatar

How to do it? Can you please tell the process here?

 

Thanks