<xsl:choose>
<xsl:when test="foo">FOO</xsl:when>
<xsl:when test="bar">BAR</xsl:when>
<xsl:otherwise>BAZ</xsl:otherwise>
</xsl:choose>
is this valid syntax... I get an error when I try to use this?
From: Kevin Rodgers <kevin(_dot_)rodgers(_at_)ihs(_dot_)com>
Reply-To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: Re: [xsl] xsl:when, xsl:otherwise question?
Date: Thu, 3 Feb 2005 12:51:46 -0700
Nick Roberts writes:
> Is it possible to implement an else-if condition using the above.
>
> All literature i've read only seems to use xsl:when and xsl:otherwise...
no
> "xsl:else-when" condition?
Isn't this:
<xsl:choose>
<xsl:when test="foo">FOO</xsl:when>
<xsl:when test="bar">BAR</xsl:when>
<xsl:otherwise>BAZ</xsl:otherwise>
</xsl:choose>
equivalent to:
if (foo) then FOO
else if (bar) then BAR
else BAZ
--
Kevin Rodgers
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--