M
Maik Seyring
hello to all of you
I have got a problem with the xslt-processor transformiix used by firefox.
The challange is to replace an special-character (within a string) with a
<br/>-tag.
it works fine with xsltproc but not with firefox(transformiix)
the code is the following:
<xsl:template name="replace-CR">
<xslaram name="input"/>
<xslaram name="search-string" select="'
'"/> <<<This is the problem
<xsl:variable name="temp"
select="string-length(substring-before($input,$search-string))"/>
<xsl:choose>
<xsl:when test="$temp or starts-with($input,$search-string)">
<xsl:value-of select="substring($input,1,$temp)"/>
<br/>
<xsl:call-template name="replace-CR">
<xsl:with-param name="input"
select="substring($input,$temp + string-length($search-string)+1)"/>
<xsl:with-param name="search-string" select="$search-string"/>
</xsl:call-template>
</xsl:when>
<xsltherwise>
<xsl:value-of select="$input"/>
</xsltherwise>
</xsl:choose>
</xsl:template>
If the search-string param is an simple char or string the template works
fine with firefox.
Any hints?
Thx Maik Seyring
I have got a problem with the xslt-processor transformiix used by firefox.
The challange is to replace an special-character (within a string) with a
<br/>-tag.
it works fine with xsltproc but not with firefox(transformiix)
the code is the following:
<xsl:template name="replace-CR">
<xslaram name="input"/>
<xslaram name="search-string" select="'
'"/> <<<This is the problem
<xsl:variable name="temp"
select="string-length(substring-before($input,$search-string))"/>
<xsl:choose>
<xsl:when test="$temp or starts-with($input,$search-string)">
<xsl:value-of select="substring($input,1,$temp)"/>
<br/>
<xsl:call-template name="replace-CR">
<xsl:with-param name="input"
select="substring($input,$temp + string-length($search-string)+1)"/>
<xsl:with-param name="search-string" select="$search-string"/>
</xsl:call-template>
</xsl:when>
<xsltherwise>
<xsl:value-of select="$input"/>
</xsltherwise>
</xsl:choose>
</xsl:template>
If the search-string param is an simple char or string the template works
fine with firefox.
Any hints?
Thx Maik Seyring