Subject: Re: [xsl] Access Root Node from namespaced node From: Josh Canfield <joshcanfield@xxxxxxxxx> Date: Wed, 22 Sep 2004 08:26:29 -0700 |
In XSL 1.0 you cannot use a variable in the match attribute of a template. Though the method of using a variable for accessing the root is sound. <xsl:value-of select="$root/something"/> Josh On Wed, 22 Sep 2004 05:42:04 +0000, Arun Sinha <arunsinha666@xxxxxxxxxxx> wrote: > Hi, > > Decalre a global variable. > > <xsl:variable name="root" select="/" /> > > And use this variable > > <xsl:template match="$root"> > > Cheers. > > Arun > > >From: "Karl J. Stubsjoen" <karl@xxxxxxxxxxxxxxxxxxxx> > >Reply-To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx > >To: <xsl-list@xxxxxxxxxxxxxxxxxxxxxx> > >Subject: [xsl] Access Root Node from namespaced node > >Date: Tue, 21 Sep 2004 21:12:04 -0700 > > > > > >Hello, > > > >I can't access the root node. I am within this named node mso:steps (a > >little XML collection within my stylesheet) and need to call out to the > >root > >node but am stuck! How can I access the root node? > > > >This: > ><xsl:apply-templates select="/"/> > > > >Within this template rule: > ><xsl:template match="mso:steps/mso:step"> > > > >Just gets me back to top level of mso:steps source and not the root source > >for the stylesheet. > > > >Karl > > > > _________________________________________________________________ > The new MSN toolbar! Your shortcut to the internet! > http://toolbar.msn.co.in/ Access a world of convenience!
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Access Root Node from nam, Arun Sinha | Thread | [xsl] Help calling templates with p, Charlie Consumer |
[xsl] xsl-fo: how do I inline a jpe, Jordan, Tom | Date | [xsl] [text nodes] Unmatching text , Chizzolini Stefano |
Month |