Hello,
I am trying to get the headline property from a component in the template the
copmonent is used.
I have a site "content-site" with the "innerContent" area. Created with
[@cms.area name="innerContent" /]. In this area I have 3 components which have
the property "headline ". In the "content-site" I want to automaticly build an
anchor-Tag menu which jumps to the components position.
To make this I tryied the following:
[code][#list content.innerContent?children as childItem]
<a>${childItem.headline}</a>
[/#list][/code]
With this I get an exception that headline property doesn´t exist in childItem,
but I have set the headline property
so I tried:
[code][#list content.innerContent?children as childItem]
<a>${childItem}</a>
[/#list][/code]
now I got the text:
node /content-site/innerContent/0
node /content-site/innerContent/00
node /content-site/innerContent/01
It seems that I have the right path for the components but now I have to
convert it to a content-node? to get the properties out of it.
Has someone a suggestion how to do this in FreeMarker.
Thanks,
kbc
--
Context is everything:
http://forum.magnolia-cms.com/forum/thread.html?threadId=8efa81b4-f809-4bef-a0eb-c68e05c93a15
----------------------------------------------------------------
For list details, see http://www.magnolia-cms.com/community/mailing-lists.html
Alternatively, use our forums: http://forum.magnolia-cms.com/
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------