<xsl:choose> <xsl:when test="$valA > $valB"> <xsl:value-of select="$maxUnder" /> </xsl:when> <xsl:when test="$valA < $valC"> <xsl:value-of select="$maxOver" /> </xsl:when> </xsl:choose>
但是,如果我敢于使用<代替& lt;它给出了一个错误......
<xsl:choose> <xsl:when test="$valA > $valB"> <xsl:value-of select="$maxUnder" /> </xsl:when> <xsl:when test="$valA < $valC"> <xsl:value-of select="$maxOver" /> </xsl:when> </xsl:choose>
System.Xml.XmlException: ‘<‘,
hexadecimal value 0x3C,is an invalid
attribute character.
那么为什么>好的而不是< ?
The ampersand character (
&
) and the
left angle bracket (<
) must not appear
in their literal form,except when
used as markup delimiters,or within a
comment,a processing instruction,or
a CDATA section. If they are needed
elsewhere,they must be escaped using
either numeric character references or
the strings “&
” and “<
”
respectively. The right angle bracket
(>
) may be represented using the
string “>
“,and must,for
compatibility,be escaped using either
“>
” or a character reference when
it appears in the string “]]>
” in content,when that string is not marking the end of a CDATA section.
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。