BTW, I prematurely sent my example without explaining why I put the
items in a variable.
At 2009-11-22 14:57 -0500, I wrote:
<!--$docs is ready with all documents-->
<!--sort by name-->
<xsl:variable name="names" select="$docs/doc/name"/>
<xsl:for-each select="$names">
<xsl:sort select="."/>
<xsl:text>
</xsl:text>
<xsl:value-of select="."/>
</xsl:for-each>
Of course you don't need the variable above, you can just work with:
<xsl:for-each select="$docs/doc/name">
<xsl:sort select="."/>
...
But I had it in my mind you were asking about *grouping* across files
and not just *sorting* across files. If you needed to group by
common names, then putting them in a variable would allow you to find
the common names and group under them as common headings.
Here are posts from 2004 and 2006 that show what you can do for
grouping once you have the variable loaded from multiple files:
http://www.biglist.com/lists/xsl-list/archives/200410/msg00412.html
http://www.stylusstudio.com/xsllist/200603/post70000.html
But in the end I realized you weren't asking for grouping and I
failed to undo the preparations I had made.
I hope this helps.
. . . . . . . . . Ken
--
Vote for your XML training: http://www.CraneSoftwrights.com/s/i/
Crane Softwrights Ltd. http://www.CraneSoftwrights.com/s/
Training tools: Comprehensive interactive XSLT/XPath 1.0/2.0 video
Video lesson: http://www.youtube.com/watch?v=PrNjJCh7Ppg&fmt=18
Video overview: http://www.youtube.com/watch?v=VTiodiij6gE&fmt=18
G. Ken Holman mailto:gkholman(_at_)CraneSoftwrights(_dot_)com
Male Cancer Awareness Nov'07 http://www.CraneSoftwrights.com/s/bc
Legal business disclaimers: http://www.CraneSoftwrights.com/legal
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--