Subject: Re: [xsl] xsl:if test = empty string, returns true|
From: "G. Ken Holman" <gkholman@xxxxxxxxxxxxxxxxxxxx>
Date: Sun, 13 May 2012 17:32:43 -0400
> And, you are looking for the adjacent node (which in your example is a text node), rather than the adjacent element (unless you are invoking saxon with the option to strip white-space text nodes from your input, in which case that is not true).
No I wasn't invoking saxon with such option, but did try nevertheless to use:
<xsl:strip-space elements="plist dict"/>
Still, even with or without those, if I assigned a value to the string, the function did capture it and showed it in the output of my original stylesheet in either case. Why does following::node() return the string's value in both cases then?
> BTW, I very rarely ever have to address text() nodes
Well, I did that to try to force the function to return a string instead of a tree :-/
As you can see there are still concepts of XSL that I am not quite grasping yet.
More than appreciated. I simply wanted to discourage answers that focused on issues that did not address my main question. Please excuse me for the prejudice.
-- Public XSLT, XSL-FO, UBL and code list classes in Europe -- Oct 2012 Contact us for world-wide XML consulting and instructor-led training Free 5-hour lecture: http://www.CraneSoftwrights.com/links/udemy.htm Crane Softwrights Ltd. http://www.CraneSoftwrights.com/s/ G. Ken Holman mailto:gkholman@xxxxxxxxxxxxxxxxxxxx Google+ profile: https://plus.google.com/116832879756988317389/about Legal business disclaimers: http://www.CraneSoftwrights.com/legal