How get page properties of a specific page? using template? or path=?¿? | Community
Skip to main content
ssammuell
May 24, 2019
Solved

How get page properties of a specific page? using template? or path=?¿?

  • May 24, 2019
  • 1 reply
  • 1957 views

Site Pages:

A

B

   ->   B2

   ->   B3

C

In B3 page i need "C" page properties, I can´t use inheretedPageProp because "C" is not a top node of B3.

Its possible get C properties  like $(... page by template of path... .title) ?¿

Thanks

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 Dinu_Arya

You should use the C page's path. First you should convert the C page's path to a resource then adapt it to Page or Node to get the jcr:title property. You can use Sightly's JavaScript Use API by passing page C's path and the required property (jcr:title).

or try below

${resolver.getResource('/path/to/page/C/jcr:content')['jcr:title']}

if the above one doesn't work,try 1st step.

1 reply

Dinu_Arya
Dinu_AryaAccepted solution
Level 6
May 24, 2019

You should use the C page's path. First you should convert the C page's path to a resource then adapt it to Page or Node to get the jcr:title property. You can use Sightly's JavaScript Use API by passing page C's path and the required property (jcr:title).

or try below

${resolver.getResource('/path/to/page/C/jcr:content')['jcr:title']}

if the above one doesn't work,try 1st step.