forrest-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ross Gardler <>
Subject Re: coding dynamicall in xdocs/ and to delimit output in meta-data?
Date Mon, 05 Sep 2005 14:59:01 GMT
Helena Edelson wrote:
> <xsl:for-each select="(articles/article[@type='foo'][position() &lt; 5 ]">
> I think the directive I am not understanding is what
> position() &lt; 5 
> is doing. Is it checking an array or vector of types and saying if not null
> return 0-4?

The last part simply says if the position of a node within the list of 
nodes returned by the previous statements is leff than 5 then include it 
in the result set. Anything in a square bracket is a test.

> And I then have those ready for my out.print?

Not sure what you mean by out.print, there is no such concept in XSLT. 
However, yes, the nodes that pass the tests in the XPath statement are 
available to whatever you have inside the for-each loop.

Like I said earlier this list is not a good place to be looking for 
general XSLT help. You would be far better going through the tutorials 
on, of course, if you have an XSLT problem specific 
to Forrest, we will be glad to help.

>  There are some things we
> need to create to make forrest more friendly for non-extranet sites I
> suspect

We are always interested in any custisations that users need to make. If 
you need them, it is likely others will too so we would like to work 
with you to incorporate relavent changes into Forrest itself.


View raw message