RE: [xsl] Removing tags automatically efter xsl transformation!

Subject: RE: [xsl] Removing tags automatically efter xsl transformation!
From: "Michael Kay" <mhkay@xxxxxxxxxxxx>
Date: Tue, 7 Aug 2001 16:34:57 +0100
>   <xsl:template match="/">
> 	<tag><xsl:value-of select="othertag"/></tag>
>   </xsl:template>
> 
> Sometimes isn't there a <othertag> in the input-xml-file. So 
> I get <tag/> in
> the output. But this is that I don't want to have.
> 
Then you have to avoid generating it.

<xsl:if test="othertag"> 
 <tag><xsl:value-of select="othertag"/></tag>
</xsl:if>

Mike Kay
Software AG

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


Current Thread