Subject: RE: [xsl] And while you're figuring out my last one.... From: Rene de Vries <RdVries@xxxxxxxxxxx> Date: Fri, 13 Jul 2001 17:02:33 +0200 |
Alright then, try this: <xsl:template match="NameAddress1" priority="10"/> <xsl:template match="RetrieveNameAndAddressRSResponse"> <xsl:apply-templates select="*[starts-with(name(),'NameAddress')]"/> </xsl:template> <xsl:template match="*[starts-with(name(),'NameAddress')]"> <xsl:if test="text()"> <br> <xsl:copy-of select="."/> </br> </xsl:if> </xsl:template> Instead of the NameAddress1-template, you could also put an xsl:if in the last template. Greetings Rene { @ @ } ^ \__/ "You don't need eyes to see, you need vision!" -----Oorspronkelijk bericht----- Van: Daniel Newman [SMTP:daniel.newman@xxxxxxxxxxx] Verzonden: vrijdag 13 juli 2001 16:32 Aan: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Onderwerp: RE: [xsl] And while you're figuring out my last one.... I don't even know the XML I'm working with :-( The actual XML is as follows::* <RetrieveNameAndAddressRSResponse> <Result>0</Result> <PostCode>M60 1AA</PostCode> <HolderDateOfBirth>00000000</HolderDateOfBirth> <NameAddress1>MRS A SMITH</NameAddress1> <NameAddress2>12 POINT STREET</NameAddress2> <NameAddress3>SPITTAL ESTATE</NameAddress3> <NameAddress4>SANDLODGE</NameAddress4> <NameAddress5>MANCHESTER</NameAddress5> <HolderTypeCode>FEM</HolderTypeCode> <HolderStatusDeceased>N</HolderStatusDeceased> <HolderStatusStopTrade>N</HolderStatusStopTrade> <HolderStatusAnnualReport>A</HolderStatusAnnualReport> <HolderNameKey>SMITH A</HolderNameKey> <HolderSystemNoteFlag>N</HolderSystemNoteFlag> <HolderSystemDRPFlag>N</HolderSystemDRPFlag> <HolderSystemPayeeFlag>N</HolderSystemPayeeFlag> <HolderSystemMergeFlag>N</HolderSystemMergeFlag> <HolderSurname>SMITH</HolderSurname> <HolderReturnMail>00000000</HolderReturnMail> <HolderOnDate>01121994</HolderOnDate> <HolderOffDate>00000000</HolderOffDate> <HolderAddedDate>01121994</HolderAddedDate> </RetrieveNameAndAddressRSResponse> So although your solution Rene was simple, it's not quite going to work (unless I create blank templates for all the Nodes!). So if anyone could let me know how to get all NameAddress nodes except for NameAddress1, I'd be most grateful. Daniel. XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] And while you're figuring, Daniel Newman | Thread | RE: [xsl] And while you're figuring, Daniel Newman |
[xsl] Keeping track of parents, Christian Cäsar | Date | RE: [xsl] Problem with xsl:with-par, Michael Kay |
Month |