Subject: Re: [xsl] combining two variables to generate XPATH From: Jeff Kenton <jkenton@xxxxxxxxxxxxx> Date: Tue, 17 Dec 2002 15:58:21 -0500 |
Is that FAQ outdated?? I know that the following code works just fine:
<xsl:template match="proc"> <xsl:call-template name="foo"> <xsl:with-param name="node" select="." /> </xsl:call-template> </xsl:template>
<xsl:template name="foo"> <xsl:param name="node"/> <xsl:for-each select="$node/branch/leaf"> <xsl:value-of select="@id" /> </xsl:for-each> </xsl:template>
What is different about a path with a single variable, and a path with two variables? Why can't I specify a second variable:
<xsl:template name="foo"> <xsl:param name="node"/> <xsl:param name="branch" select="'someBranch'"/> <xsl:for-each select="$node/$branch/leaf"> <xsl:value-of select="@id" /> </xsl:for-each> </xsl:template>
-- -------------------------- Jeff Kenton DataPower Technology, Inc.
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] combining two variables t, Robert Koberg | Thread | Re: [xsl] combining two variables t, Jeff Kenton |
RE: [xsl] combining two variables t, Robert Koberg | Date | [xsl] "White Space" error message, Denis Nwanshi |
Month |