|
Subject: RE: [xsl] document() and node-list vs. tree fragment From: "Michael Kay" <mhkay@xxxxxxxxxxxx> Date: Thu, 27 Sep 2001 17:37:50 +0100 |
> On Linux Xalan C++ v 1.1 I can use
>
> <xsl:variable name="f2">
> <xsl:copy-of select="document('testfile2.xml')"/>
> </xsl:variable>
>
> and later
>
> <xsl:apply-templates select="$f2"/>
>
It's not allowed in XSLT 1.0; it is allowed by the "defunct" XSLT 1.1
working draft. In XSLT 1.0, $f2 is not a node-set, it is a result tree
fragment; to convert it to a node-set, you have to use the product-specific
node-set() extension function.
But why are you doing this?
What's wrong with <xsl:apply-templates select="document('testfile2.xml')"/>?
Or if you must have a variable,
<xsl:variable name="f2" select="document('testfile2.xml')"/>?
Mike Kay
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| [xsl] document() and node-list vs. , Michael Case | Thread | RE: [xsl] document() and node-list , Chris Bayes |
| RE: [xsl] Template Matching, Michael Kay | Date | RE: [xsl] SAXON and UTF-8, Julian Reschke |
| Month |