Re: [xsl] multiple node values not being returned

Subject: Re: [xsl] multiple node values not being returned
From: Rahil <qamar_rahil@xxxxxxxxxxx>
Date: Fri, 20 May 2005 14:38:38 +0100
David Carlisle wrote:

All I want is a check if there are any A/Values present in the B node set.


yes, but in relation to your "one line" question, the answer depends on what you want to do. You can do that check with a single XPath, but if you need to generate element nodes then since you can't generate nodes with core Xpath functions then you need to write it as xsl, which tends to take more lines, as you have to close the elements.




Yeah, it would be nice if what I wanted could be done in "one" line and you showed me as well. But for some reason doesnt give me the desired result. All it outputs is the first value 'Handle'. Im not sure why it does so except for the reason that <xsl:value-of> returns one value.

However if I try to write the expression as
<xsl:value-of select="distinct-values($aNode/Value[for $a in . return $oNode/Value[contains(.,$a)]])"/> then it returns 'Handle' thrice instead of 'Handle Bolt'.



Rahil


Current Thread