Re: [xslt] string literal with single-quote inside won't parse



2009/9/11 Viktor Štujber <theultramage gmail com>:
> Hello. I noticed that libxslt errors out if I try to use a
> single-quoted string literal with a single-qoute (') or &apos; inside
> it. I know it can be worked around using a temporary variable to store
> the literal, however I'm curious whether this issue will be resolved
> someday, or whether it is 'a feature'.

Your attached example is an error by the spec, you can instead write it like:
<xsl:value-of select="&quot;Hello, I'm a literal with an apostrophe
inside.&quot;"/>
or:
<xsl:value-of select='"Hello, I&apos;m a literal with an apostrophe inside."'/>

Martin


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]