Forums de discussion

How to get parent page details for a community. Finding parent pages.!

thumbnail
Parag Negi, modifié il y a 12 années.

How to get parent page details for a community. Finding parent pages.!

Junior Member Publications: 69 Date d'inscription: 31/08/11 Publications récentes
Hi Guyz,

Can someplease advise me how can i get ( page name, page id, page friendly url ) for a community(based on cummunity id)

Also is there any way to go backwads on a page(like going to parent pages and so on.... till the root page is reached).
So, that you can get parent page of the current page. That will be a Great help, if it's possible.

So, that if i am at page 'D'.
Then it's parent pages 'A' 'B' 'C' can be found .

Please help....
Kind Regards,
Parag
thumbnail
Samuel Kong, modifié il y a 12 années.

RE: How to get parent page details for a community. Finding parent pages.!

Liferay Legend Publications: 1902 Date d'inscription: 10/03/08 Publications récentes
To get pages in a community:

LayoutLocalServiceUtil.getLayouts(long groupId, boolean privateLayout)

To get a parent page (assume current page is in the var "layout"),

layout.getParentLayoutId()
thumbnail
Parag Negi, modifié il y a 12 années.

RE: How to get parent page details for a community. Finding parent pages.!

Junior Member Publications: 69 Date d'inscription: 31/08/11 Publications récentes
Hi Samuel,

Thanks very much for your reply.

Is there anyway to get home page of community??
Please advise.

Thanks and Regards,
Parag Negi
Meera Alukkal, modifié il y a 9 années.

RE: How to get parent page details for a community. Finding parent pages.!

New Member Envoyer: 1 Date d'inscription: 22/05/14 Publications récentes
Use

layout.getAncestors()
to get the root