Re: "uriref()" XPath function?
I notice there's an "idref()" XPath function which returns nodes which reference a specified id
Actually, it's id() that does that - idref() does the inverse.
Theoretically, the document() function will do this. However, processing of fragment identifiers is a little fragile - technically it depends on the media type of the document being known, since the semantics of fragment identifiers depend on the media type. You might be better off using id(substring(@href, 2)).- however the document I'm processing references ids with URIs, e.g.<a href="#foo"/> references id "foo"
Michael Kay Saxonica
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