cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Oliver <res1c...@verizon.net>
Subject Re: #{//foo/bar} doesn't work within forEach!
Date Sun, 18 Apr 2004 19:09:33 GMT
No. That won't work. With the current implementation of JXTG XPath 
evaluation of absolute paths with a <forEach> only works if the 
expression passed to <forEach> is an XPath expression. Does this work:

<jx:forEach var="something" items="#{myList}">

  #{//foo/bar}

</jx:forEach>


Chris



Stephan Coboos wrote:

> Hello,
>
> I've tried to retrieve an object within a JXTemplate:
>
> #{//foo/bar}
>
> This works fine outside any "forEach". If I'am using it inner forEach, 
> nothing will be printed out:
>
> <jx:forEach var="something" items="${myList}">
>
>   #{//foo/bar}
>
> </jx:forEach>
>
> Because // refers to the root, the value should be printed out within 
> this context, right? Whats wrong?
>
> Thank you.
>
> Regards
> Stephan
>


Mime
View raw message