This looks like Xquery syntax... for and return are constructs of a
FLWOR expression. Along with the other posts regarding the collection
funciton itself, you want syntax like
"collection('../test/xdocs?select=*.xml;recurse=yes;on-error=warn')//def
inition"... Since you have a query string, I am assuming you are trying
to use the result of a cocoon pipeline in your xslt? In that case, you
could either use document(), which is not recommended, or you can
aggregate these documents into your source document before processing
with the XSLT
Chris Marasti-Georg
> -----Original Message-----
> From: bokluk [mailto:[EMAIL PROTECTED]
> Sent: Monday, January 30, 2006 5:08 PM
> To: [email protected]
> Subject: collection() error
>
> (How) is collection function implemented in cocoon?
> I tried following code:
>
> <xsl:for-each select="for $x in
> collection('../test/xdocs?select=*.xml;recurse=yes;on-error=wa
> rn') return $x//defnition">
>
> <xsl:sort select="@title"/>
>
> TITLE=<xsl:value-of select="@title"/><br/>
>
> </xsl:for-each>
>
> And it gave me following error:
>
> Extra illegal tokens: '$', 'x', 'in', 'collection', '(',
> ''../prosa/xdocs?select=*.xml;recurse=yes;on-error=warn'',
> ')', 'return', '$', 'x', '/', '/', 'defnition'
>
> What am I missing?
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]