|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: xpath index-of function using xslt 3.0
Hi Martin,
Thanks for insightful discussion about this mail thread.
On Fri, Oct 3, 2025 at 7:55b/PM Martin Honnen martin.honnen@xxxxxx <
xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> wrote:
>https://www.w3.org/TR/xpath-functions-31/#func-index-of says
>The items in the sequence $seq are compared with $search under the rules
for the eq operator. Values of type xs:untypedAtomic are compared as if
they were of type xs:string. Values >that cannot be compared, because the
eq operator is not defined for their types, are considered to be distinct.
If an item compares equal, then the position of that item in the sequence
>$seq is included in the result.
>So if you use = instead of eq you are not implementing the XPath 3.1
function 'index-of'
I've tested my XSL stylesheet written previously within this mail thread,
with following changes as suggested by you,
<xsl:if test=". eq $srch1">
<!-- code -->
</xsl:if>
and also with
not(. ne $srch1) <!-- for my interest -->
With both of these XSL stylesheet code modifications, an XSL stylesheet
example that I've written previously, works fine with Apache Xalan XSLT
3.0's development code.
Thanks, to Mike as well, for his suggestions that I'll try with little
later.
--
Regards,
Mukul Gandhi
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








