Hi Thanks for helping me resolve the issue.
Cheers Amin On Fri, Apr 3, 2009 at 7:52 AM, Amin Mohammed-Coleman <[email protected]>wrote: > Hi > JIRA raised: > > https://issues.apache.org/struts/browse/TILES-391 > > This JIRA is related to the tiles 2.1.2 and freemarker usage. It does not > look at the trunk code as this is under development. > > Cheers > Amin > > > On Sat, Mar 28, 2009 at 2:52 PM, Amin Mohammed-Coleman > <[email protected]>wrote: > >> >> Hi >> >> I have a java object which I am passing into a tiles tag. For example: >> >> I can print out pcobj outside of the tags >> >> >> <@tiles.insertDefinition name="pagination.tile"> >> <@tiles.putAttribute name="personalContact" value=pcobj /> >> </@tiles.insertDefinition> >> >> >> in my pagination tile I am doing: >> >> >> <@tiles.importAttribute name="personalContact" /> >> >> EMAIL : ${personalContact.email} <br/> >> FIRST NAME: ${personalContact.firstName} <br/> >> LAST NAME: ${personalContact.lastName} <br/> >> >> >> However I am getting the following >> >> Attribute with name 'personalContact' not found >> The problematic instruction: >> ---------- >> ==> user-directive tiles.importAttribute [on line 3, column 1 in >> WEB-INF/freemarker/pagination.ftl] >> ---------- >> >> Java backtrace for programmers: >> ---------- >> freemarker.template.TemplateModelException: Attribute with name >> 'personalContact' not found >> at >> >> freemarker.ext.jsp.TagTransformModel$TagWriter.onStart(TagTransformModel.java:479) >> at freemarker.core.Environment.visit(Environment.java:230) >> at freemarker.core.UnifiedCall.accept(UnifiedCall.java:116) >> at freemarker.core.Environment.visit(Environment.java:196) >> at freemarker.core.MixedContent.accept(MixedContent.java:92) >> at freemarker.core.Environment.visit(Environment.java:196) >> at freemarker.core.Environment.process(Environment.java:176) >> at freemarker.template.Template.process(Template.java:232) >> >> >> I would be grateful if anyone could advise me on what i'm doing wrong.. >> >> Cheers >> >> Amin >> > >
