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

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

Avatar

Avatar
Establish
Community Manager
kautuk_sahni
Community Manager

Likes

1,127 likes

Total Posts

6,116 posts

Correct Reply

1,144 solutions
Top badges earned
Establish
Coach
Originator
Contributor 2
Contributor
View profile

Avatar
Establish
Community Manager
kautuk_sahni
Community Manager

Likes

1,127 likes

Total Posts

6,116 posts

Correct Reply

1,144 solutions
Top badges earned
Establish
Coach
Originator
Contributor 2
Contributor
View profile
kautuk_sahni
Community Manager

19-03-2021

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.

AEM AEMEBlogSeeding Experience Manager