[osflash] xfactor studio xpath ignore case function ?

Allen, Christopher S. CSALLEN at PARTNERS.ORG
Mon Dec 5 17:27:42 EST 2005


Hey Grant,

I know that there was a way to create custom functions to extend the native
Xpath functions.

This was taken from an older version of his site at:
http://www.xfactorstudio.com/Actionscript/AS2/XPathNew/
 
" Custom Functions
You can extend the native XPath functions using the registerFunction static
method of the XPathFunctions Object. Look in the source code of
XPathFunctions.as to see how this is done."

I hope that helps somewhat.

-Chris

-----Original Message-----
From: osflash-bounces at osflash.org [mailto:osflash-bounces at osflash.org] On Behalf
Of grant at bluetube.com
Sent: Monday, December 05, 2005 5:06 PM
To: osflash at osflash.org
Subject: [osflash] xfactor studio xpath ignore case function ?


I'm using the following xpath query to find all products who's name contains the
word "spoon"

XPath.selectNodes(myXML,"//products/product[contains(name,'Spoon')")

is there a way to also ignore the case, or convert the document to upper case
before searching ?

I see that xpath is supposed to have a string function upper-case but I can't
figure out how to incorporate it into my contains call.

Grant



More information about the osflash mailing list