如何从XSLT访问CDATA中的变量? [英] How to access variable in CDATA from XSLT?
本文介绍了如何从XSLT访问CDATA中的变量?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用XSLT Transformation,需要将一些数据放在CDATA节中,并且该变量存在于变量中。
I am using XSLT Transformation and need to put some data in CDATA section and that vale is present in a variable.
查询:如何访问CDATA中的变量?
示例如下:
Query: How to access variable in CDATA ? Sample Given Below:
<xsl:attribute name ="attributeName">
<![CDATA[
I need to access some variable here like
*<xsl:value-of select ="$AnyVarible"/>*
]]>
</xsl:attribute>
如何在CDATA中使用varibale?
注意:我不能使用-> & lt;![CDATA [< xsl:value-of select = $ AnyVarible />]]& gt;
预先感谢。
How can I use varibale in CDATA ?
Note: I can not use --> <![CDATA[<xsl:value-of select ="$AnyVarible"/>]]>
Thanks in advance.
推荐答案
我已经为此解决了...大家...
I got the solution for this...FYI for everyone...
<xsl:text
disable-output-escaping="yes"><![CDATA[</xsl:text>
<xsl:value-of select ="$AnyVarible"/>
<xsl:text
disable-output-escaping="yes">]]></xsl:text>
这篇关于如何从XSLT访问CDATA中的变量?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文