Subject: Re: [xsl] How to output partial elements? From: "Marrow" <marrow@xxxxxxxxxxxxxx> Date: Tue, 20 Aug 2002 10:55:34 +0100 |
Hi Jem, Something like?... == XSL ================================== <?xml version="1.0"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:key name="kPreceding-normal" match="record[@type != 'normal']" use="generate-id(preceding-sibling::record[@type='normal'][1])"/> <xsl:template match="/"> <xsl:apply-templates/> </xsl:template> <xsl:template match="*"> <xsl:copy> <xsl:copy-of select="@*"/> <xsl:apply-templates/> </xsl:copy> </xsl:template> <xsl:template match="record[@type='normal']"> <xsl:copy> <xsl:copy-of select="@*"/> <xsl:copy-of select="node()|key('kPreceding-normal',generate-id())/node()"/> </xsl:copy> </xsl:template> <xsl:template match="record[@type!='normal']"/> </xsl:stylesheet> == end of XSL ============================= Hope this helps Marrow http://www.marrowsoft.com - home of Xselerator (XSLT IDE and debugger) http://www.topxml.com/Xselerator XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] How to output partial ele, Américo Albuquerque | Thread | RE: [xsl] How to output partial ele, Stuart Brown |
[xsl] How to output partial element, Jem Clear | Date | RE: [xsl] How to output partial ele, Stuart Brown |
Month |