Reputation: 19107
I have this XSL snippet:
<xsl:if test="@BookmarkId">
<a>
<xsl:attribute name="name">
<xsl:value-of select="concat('week', @BookmarkId)"/>
</xsl:attribute>
</a>
</xsl:if>
The output is:
<a name="week1"/>
But in this instance I require it to be:
<a name="week1"></a>
How can I do this?
Thank you.
Upvotes: 0
Views: 31
Reputation: 460
Please use this solution
<xsl:if test="@BookmarkId">
<a>
<xsl:attribute name="name">
<xsl:value-of select="concat('week', @BookmarkId)"/>
</xsl:attribute>
<![CDATA[ ]]>
</a>
</xsl:if>
Upvotes: 2