This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Selecting nodes whose text content contains a member of a Node-set...


> Basically, I wante to implement a very basic form of partial
> string matching
> which I think should be possible in XSLT. Basically, I only
> want to select
> nodes from a node-set whose text content contains one member
> of another node-set.

The "=" operator, when applied to two node-sets, tests whether there is a
node in the first node-set whose string-value is equal to the string-value
of some node in the second node-set.

So your problem is easy:

<xsl:if test="xx:tokenize($param) = $words">

Mike Kay

>
> Can anyone help with this....
>
> Basically, I am using Xalan, and passing a String as a
> parameter. I could then
> use Xalan's tokenize function to create a node-set containing
> all the "words"
> in the passed parameter. Now I want to check that one of the
> members of the
> "words" node-set is contained in the text node on which I'm
> basing selection.
>
>


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]