【发布时间】:2013-07-04 11:16:14
【问题描述】:
我找不到这个问题的确切答案,所以我希望有人能在这里帮助我。
我有一个字符串,我想得到最后一个'.'之后的子字符串。我正在使用 xslt 1.0。
这是怎么做到的?这是我的代码。
<xsl:choose>
<xsl:otherwise>
<xsl:attribute name="class">method txt-align-left case-names</xsl:attribute> 
<xsl:value-of select="./@name"/> // this prints a string eg: 'something1.something2.something3'
</xsl:otherwise>
</xsl:choose>
当我粘贴建议的代码时,我收到一条错误消息。 “解析 XSLT 样式表失败。”
【问题讨论】:
标签: xslt