[Home] [By Thread] [By Date] [Recent Entries]

Subject: RE: xsl:if statement with numeric
From: "Andreas L. Delmelle" <a_l.delmelle@xxxxxxxxxx>
Date: Sun, 28 Mar 2004 12:22:49 +0200
> -----Original Message-----
> From: Andreas L. Delmelle [mailto:a_l.delmelle@xxxxxxxxxx]
> 
<snip />

> Then you could avoid all the xsl:choose / xsl:if logic by merely fetching
> the color value corresponding to the number value in question, like
> 
> <xsl:template match="monat">
>   <td bgcolor="{/colormap/color[@min &gt;= number(current())][1]/@color}"
>       align="right">
> ...

Hmm. Maybe needs some extra braces:

bgcolor="{(/colormap/color[@min &gt;= number(current())]
           )[1]/@color}"


Cheers,

Andreas

Current Thread
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member