RE: beginner problem with attlist

Subject: RE: beginner problem with attlist
From: Kay Michael <Michael.Kay@xxxxxxx>
Date: Mon, 17 Jan 2000 09:52:43 -0000
> Now it looks like:
> 
> <xsl:for-each select="Dokument">
>     <xsl:choose>
>       <xsl:when test=".[@Art='Rechnung']">
> 
>          <xsl:for-each select="Dokument/Adresse">

The first <xsl:for-each> changes the current node to be a Dokument. Your
second <xsl:for-each> will select the Adresse children of the Dokument
children of the current node. Unless you have Dokument elements nested
within Dokument elements, I suspect the second <xsl:for-each> should be
<xsl:for-each select="Adresse">.

Incidentally, the <xsl:when> here will work but is very contorted. Much
simpler to write <xsl:when test="@Art='Rechnung'">

Mike Kay


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread