You are viewing a plain text version of this content. The canonical link for it is here.
Posted to general@xml.apache.org by Da...@lotus.com on 2000/10/30 22:57:18 UTC

Re: Preventing arithmetic parsing of expressions that look like arith metic

Steve Cohen writes:
>I define a parameter in a stylesheet:
> <xsl:param name="season" select="2000-01"/>
>When I output the value of "$season" somewhere, I get "1999".
>It is performing the subtraction it thinks I want.

Try <xsl:param name="season" select="'2000-01'"/>, which has
the two sets of quotes. If that doesn't work, or if you want
more flexibility, try
<xsl:param name="season" select="concat('2000','-01')"/>
The concat() function coerces each of its arguments to be a
string before concatenating them.
.................David Marston