Wrapping element in choose construction. How to improve?
Posted
by Kalinin
on Stack Overflow
See other posts from Stack Overflow
or by Kalinin
Published on 2010-05-18T09:49:12Z
Indexed on
2010/05/18
13:10 UTC
Read the original article
Hit count: 177
Is there any way to optimize this code.
<xsl:when test="val1 = val2">
<xsl:apply-templates select="node"/>
</xsl:when>
<xsl:otherwise>
<div>
<xsl:apply-templates select="node"/>
</div>
</xsl:otherwise>
I do not like having to write twice the same <xsl:apply-templates select="node"/>
.
© Stack Overflow or respective owner