Subject: RE: more on Using apply-templates instead of for-each?
From: David Carlisle <davidc@xxxxxxxxx>
Date: Tue, 15 Apr 2003 21:03:22 +0100
|
> For-each does operate on each node in a node-set, but they are operated
> on separately, as if they were single, unrelated nodes. With for-each,
> for example, you can only get a position() of 1 on any one iteration,
Not at all. see the example in the spec that uses position() in a
for-each to not put a comma after the last item in a list.
for-each is just the same as an apply-templates that uses a private mode
and a single template that matches all nodes.
David
________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
| Current Thread |
- RE: more on Using apply-templates instead of for-each?, (continued)
- Passin, Tom - Tue, 15 Apr 2003 14:48:06 -0400 (EDT)
- Kathy Burke - Tue, 15 Apr 2003 14:56:31 -0400 (EDT)
- Passin, Tom - Tue, 15 Apr 2003 15:24:47 -0400 (EDT)
- Passin, Tom - Tue, 15 Apr 2003 15:31:30 -0400 (EDT)
- David Carlisle - Tue, 15 Apr 2003 15:59:27 -0400 (EDT) <=
- Passin, Tom - Tue, 15 Apr 2003 16:38:51 -0400 (EDT)
- Kathy Burke - Tue, 15 Apr 2003 16:50:48 -0400 (EDT)
|
|