<xsl:when> on more than one selection

Kniffel

Usenet Archive
Joined
May 18, 2007
Messages
13
Reaction score
0
Hi

Is there a possibility to make an <xsl:when> on more than one Selection?

Not that way:
<xsl:choose>
<xsl:when a=test>
Do this
<xsl:when a=test2>
Do this
<xsl:when a=test3>
Do this
<xsl:eek:therwise>
Do something else

More this way:
<xsl:choose>
<xsl:when a=test or a=test2 or a=test3>
Do this
<xsl:eek:therwise>
Do something else

Part of my xsl-file:
<xsl:variable name="attr" select="name" />
<xsl:variable name="attrwert" select="." />
<xsl:choose>
<xsl:when test="$attr='Aktiv'">
Do this
</xsl:when>
....
</xsl:choose>
</xsl:choose>

In regards
Kniffel
 

Dimitre Novatchev

Usenet Archive
Joined
Nov 7, 2000
Messages
737
Reaction score
0
Kniffel said:
Hi

Is there a possibility to make an <xsl:when> on more than one
Selection?
Yes

Not that way:
<xsl:choose>
<xsl:when a=test>
Do this
<xsl:when a=test2>
Do this
<xsl:when a=test3>
Do this
<xsl:eek:therwise>
Do something else

More this way:
<xsl:choose>
<xsl:when a=test or a=test2 or a=test3>
Do this
<xsl:eek:therwise>
Do something else

Part of my xsl-file:
<xsl:variable name="attr" select="name" />
<xsl:variable name="attrwert" select="." />
<xsl:choose>
***************************************************************
<xsl:when test="$attr='Aktiv'">
Do this
***************************************************************
</xsl:when>
....
</xsl:choose>
</xsl:choose>

In regards
Kniffel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
548,049
Messages
3,104,244
Members
248,133
Latest member
DujonT

Latest Threads

Top