Subject: Re: xsl:template node set parameter From: Jeni Tennison <mail@xxxxxxxxxxxxxxxx> Date: Fri, 25 Aug 2000 21:17:28 +0100 |
>Can I pass a set of nodes as a parameter to a template? Yes, but "node sets" in XSLT terminology are sets of nodes from the source document, not sets of nodes that you generate within the stylesheet. You can make a parameter or variable take a node set as a value by setting that value with the 'select' attribute. When you set a parameter or variable value using the content of the parameter or variable, then you create a "result tree fragment", which is exactly what it says on the tin - a fragment of the result tree. Result tree fragments aren't the same as source nodes, and you can do only limited things with them. One of the things that you *can't* do is process them in any way. Some processors have extension functions that allow you to convert result tree fragments into node sets. I'm not sure if Xalan has one or how to use it, but I'm sure someone else does. Without using an extension function, you may have to do two passes: one pass creating a result that you then use as the input to the next pass. But you haven't given enough details of your actual problem to tell whether this is necessary. Sorry not to be more help, Jeni Jeni Tennison http://www.jenitennison.com/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
xsl:template node set parameter, xsl list | Thread | Re: xsl:template node set parameter, Gary L Peskin |
[no subject], Dave Pawson | Date | Re: xsl:template node set parameter, Gary L Peskin |
Month |