Subject: RE: [xsl] Using document() and getting back to the original doc From: "Andreas L. Delmelle" <a_l.delmelle@xxxxxxxxxx> Date: Mon, 22 Mar 2004 20:13:07 +0100 |
> -----Original Message----- > From: Dan Vint [mailto:dvint@xxxxxxxxx] > > > I know how to start a style sheet with a new document using the > document() function, but how do you get back to the document that > was feed in on the command line? > Hi, Errrm... this should be always in scope for the stylesheet, so I don't really see why you would need to 'open' it again... If you want to make sure you don't lose track, you can always add a global variable: <xsl:variable name="vdoc" select="/" /> to your stylesheet. an expression like '$vdoc/root/node' will then always refer to '/root/node' from your 'original input document', and the following: <xsl:copy-of select="$vdoc" /> will insert a copy of the source document into the result tree. Hope this helps! Cheers, Andreas
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Using document() and gett, Wendell Piez | Thread | Re: [xsl] Using document() and gett, Eliot Kimber |
RE: [xsl] FW: key, generate-id, ign, Michael Kay | Date | Re: [xsl] Using document() and gett, Eliot Kimber |
Month |