[xsl]cascading evaluation of variables

Subject: [xsl]cascading evaluation of variables
From: "Janvier Majirus FANSI" <jmfansi@xxxxxxxxxxx>
Date: Mon, 11 Oct 2004 12:02:03 +0200
Hi all,
I have this following template rule within my stylesheet. I have a problem with a cascade evaluation of variable.


the template is:
<xsl:template match="object">
<xsl:variable name="select"><xsl:value-of select="@select"/></xsl:variable>

<xsl:variable name="path1"><xsl:value-of select="concat('document($sourcefile)/descendant-or-
self::',$select,'/parent::node()')"/>
</xsl:variable>


<xsl:variable name="essai"><xsl:value-of select="$path1"/>
</xsl:variable>

<xsl:value-of select="$path1"/>
<xsl:value-of select="$essai"/>
</xsl:template>

the results are:

<xsl:value-of select="$path1"/> return the string 'document($sourcefile)/descendant-or-self::files/record/parent::node()'.
<xsl:value-of selec="$essai"/> return the same string instead of the nodes set resulting to its evaluation.


I expected that variable $essai was take like entry the result of evaluation of $path1, and return the results nodes set.

Could anyone know, please, what is wrong in my declaration?
I thank all of you in advance.

regards

Majirus

_________________________________________________________________
Hotmail : bienttt 250 Mo de stockage ! http://www.imagine-msn.com/hotmail/fr-fr/


Current Thread