[xsl] A node-set from concat()

Subject: [xsl] A node-set from concat()
From: "Foxy Shadis" <foxyshadis@xxxxxxxxxxx>
Date: Sun, 20 Apr 2003 19:58:01 -0700
I'm trying to open up multiple documents with an interface like:

document(concat($journal/external[@name='journal']/@href,'.xjour'))/entries/entry

Obviously this won't work, since concat uses only the string value of the first node in any node-sets passed to it, returning a single string. I'd just like a similar function that concatenates each item in the node-set to other items in node-sets and strings. (Whether it would go over multiple node-sets in a multi-dimensional matrix or only the first node-set, I don't care at this point.) At the moment the only solution seems to be using yet another hack with a node-set extension.

I could put the extension back in the main file, but it would be difficult to use if I changed the extension (also, if I later change the folders the files are stored in, one for each user perhaps), and this acts as a security mechanism. Perhaps I should simply use an EXSLT function, since I wish to strip any dot and slash characters anyway. Would still need node-set(), however, at least until XPath 2.0 support is in Xalan.

I'm not sure whether keys could be turned to work, but I am sure they would be far too much trouble; all data comes from document() functions, the "input" being a null xml file, and "match" keys are difficult to use with multiple sources.

Swiftpaw Foxyshadis, wildlife artist
foxyshadis@xxxxxxxxxxx | http://foxyshadis.dyndns.org/
http://foxyshadis.dyndns.org/journal/foxyshadis

_________________________________________________________________
STOP MORE SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail



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



Current Thread