In <48**********************@newsspool2.arcor-online.netMartin Honnen <ma*******@yahoo.dewrites:
Which XSLT processor are you using?
I'm using the libxslt package in python.
Obviously the snippet you posted can be reduced to
<a href="{xyz}">
</a>
Yes, I've changed to this shorthand method and it has helped.
Are you sure the whitespace and the escaping does not result from
evaluating xyz and applying HTML href escaping?
I thought it might be an href escaping issue, but then I noticed the
same thing happening when I was setting a variable and then using the
value in a hidden form input element, like so:
<xsl:variable name="actionType">
<xsl:choose>
<xsl:when test="something">
someValue
</xsl:when>
<xsl:otherwise>
someOtherValue
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
....
<form>
<input type="hidden" name="actionType">
<xsl:attribute name="value">
<xsl:value-of select="$actionType" />
</xsl:attribute>
</input>
</form>
The value of the form element contained the embedded newline and tabs.
When I changed the hidden form element to use the shorthand {} notation
the problem still persisted; it was only fixed by editing the variable
declaration and removing all the whitespace between the beginning and
ending <xsl:whenand <xsl:otherwisetags, like so:
<xsl:variable name="actionType">
<xsl:choose>
<xsl:when test="something">someValue</xsl:when>
<xsl:otherwise>someOtherValue</xsl:otherwise>
</xsl:choose>
</xsl:variable>
--
John Gordon A is for Amy, who fell down the stairs
go****@panix.com B is for Basil, assaulted by bears
-- Edward Gorey, "The Gashlycrumb Tinies"