cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Leangen" <dlean...@canada.com>
Subject JXTemplate - forEach
Date Sat, 01 May 2004 12:10:38 GMT

I have a question about jx:forEach.

I would like to consistently use either Jexl or JXPath. In my case, I have
chosen JXPath.

I have a <jx:forEach> construct as follows:

  <jx:forEach select="#{pageComponents}">
    <ci:include src="skins/#{skinName}/#{.}.xml"/>
  </jx:forEach>


The problem is that I am getting this error:

org.apache.cocoon.ProcessingException: Failed to execute pipeline.:
file:/path/to/jx/file:org.apache.commons.jxpath.JXPathException: No pointer
for xpath: skinName



However, if I do the following (with Jexl), everything is ok:

  <jx:forEach select="#{pageComponents}">
    <ci:include src="skins/${skinName}/#{.}.xml"/>
  </jx:forEach>


The following also causes no problems when the #{skinName} is not inside the
<jx:forEach>:

    #{skinName}

  <jx:forEach select="#{pageComponents}">
    whatever
  </jx:forEach>


So this is really related to the use of a JXPath expression in the
<jx:forEach> construct.


Can anybody explain why this is happening?


Thanks!



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message