Re: [xsl] Cannot process a result tree fragment as a node-set under XSLT 1.0 - The extension don´t function

Subject: Re: [xsl] Cannot process a result tree fragment as a node-set under XSLT 1.0 - The extension don´t function
From: Michael Ludwig <mlu@xxxxxxxxxxxxx>
Date: Fri, 18 Apr 2008 10:38:17 +0200
ALEXCONTINI@xxxxxxxx schrieb:
Hi,

the extension don't function, whatB4s up?

Try and build a *minimal* example using just one RTF variable, one template and the exsl:node-set() function. If it still doesn't work, post your minimal example together with the precise error message your processor gives you, and the name of your processor, too.

Okay, try the following minimal example:

<xsl:transform version="1.0"
  xmlns:exsl="http://exslt.org/common";
  extension-element-prefixes="exsl"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
  <xsl:variable name="filtro">
    <Elm/>
    <Elm/>
  </xsl:variable>
  <xsl:template match="/">
    <xsl:comment>
      <xsl:value-of select="system-property('xsl:vendor')"/>
    </xsl:comment>
    <xsl:variable name="total" select="count(exsl:node-set($filtro)/Elm)"/>
    <Res>
      <xsl:copy-of select="$total"/>
    </Res>
  </xsl:template>
</xsl:transform>

The output should be:

<!--name of you processor-->
<Res>2</Res>

Michael

Current Thread