Is it possible to get parent page?

Hi,

Is there a way to get first ParentPage from PageService or some other service?

For example given this setup below, is it possible from Page 3.2 get the Page 3?

Website
|_Page 1
|_Page 2
|_Page 3
…|_Page 3.1
…|_Page 3.2 <----- From Here

I could probably do a db query since i looked in the db where they list ParentPageSystemId in Sites.Page or in worst case do a url check and try to process through that? Or if you recommend some other way?

Litium version: 7.2.3

Thanks in advance
Best Regards
Artur O.

The ParentPageSystemId is available as a property on the Page entity if you want to retrieve it. The PageModel contains the Page.

Hi,

I was gnawing on the evening that the entity should have it. It was exactly what I wanted.

Have a great day and thanks for the quick reply.
Best Regards
Artur O.

1 Like

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.