How to get child page properties(image,title,description) using servlet in base path. | Community
Skip to main content
Level 2
January 9, 2022
Solved

How to get child page properties(image,title,description) using servlet in base path.

  • January 9, 2022
  • 2 replies
  • 1293 views

i have java servlet where it can collect only child pages title , but i want which collects all the child pages properties not only title , I want description and image inside of  child pages  like page listing component.

It is similiar like below picture 

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Apmag

Hi Krishna,

 

Just want to share my thoughts, are you using slingmodes exporter components on child pages?

 

If yes - just write generalized servlet resource Type and the call the all the models as well as it will  give complete JSON object.

 

Thanks,

Nani.

2 replies

BrianKasingli
Community Advisor and Adobe Champion
Community Advisor and Adobe Champion
January 10, 2022

@krishna0427,

I suggest you looking at the implementation of the servlet, and then extend it to expose more than just the title of each child page. There might be a POJO model Java class that you may need to extend, to output more properties as you mentioned. 

Level 2
January 10, 2022

yes , how can i get child page information like title, text, image and show that component as all articles component. 

Can u share any references , i will go through it . 

BrianKasingli
Community Advisor and Adobe Champion
Community Advisor and Adobe Champion
January 10, 2022
ApmagAccepted solution
Level 3
January 10, 2022

Hi Krishna,

 

Just want to share my thoughts, are you using slingmodes exporter components on child pages?

 

If yes - just write generalized servlet resource Type and the call the all the models as well as it will  give complete JSON object.

 

Thanks,

Nani.