[ http://jira.magnolia.info/browse/MAGNOLIA-2267?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18012#action_18012 ]
Philipp Bracher commented on MAGNOLIA-2267: ------------------------------------------- the problem is the consistency between jsp and freemarker. content.getParent() does not work in EL. Anyway if we implement the following resolution rules: - nodedata - child node - property it will work fine for 99%. In case you have a nodedata = getter conflict and you don't want the nodedata value (which is less likely in templates) you can fall back to the explicit method notation. > Provide easy access to content parent in freemarker paragraph > ------------------------------------------------------------- > > Key: MAGNOLIA-2267 > URL: http://jira.magnolia.info/browse/MAGNOLIA-2267 > Project: Magnolia > Issue Type: Improvement > Components: templating > Reporter: Jan Haderka > Assignee: Jan Haderka > Fix For: 3.7 > > > Currently there is no simple way to obtain parent of current piece of content > in freemarker paragraph. Ideally something like ${content.parent} would > provide access to the content parent. > It can be achieved by simple change in {{i.m.f.ContentModel}} -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.magnolia.info/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira ---------------------------------------------------------------- for list details see http://documentation.magnolia.info/ ----------------------------------------------------------------