Re: [xslt] extension functions returning node-sets

On Mon, Mar 03, 2003 at 03:00:24PM -0700, Vakoc, Mark wrote:
> Which is the correct syntax for retrieving the second node from an extension
> returning a node-set?  This behavior appears to have changed in recent
> versions of libx*.
> Given:
> <xsl:variable name="test" select="str:tokenize('bob smith')"/>

  hum, what is str:tokenize ? I'm surprized it can return a node set
since there is no tree on input.

> Is it
> 1)
> <xsl:value-of select="$test[2]"/>

  Hum that should be that one I think.

> or
> 2)
> <xsl:value-of select="$test/token[2]"/>
> I thought it was number 2, but number 1 is the only one that works.  I seem
> to remeber two as working before in libx*
> Thoughts?

  I lack the str:tokenize context information. Looks weird, I have a hard
time seeing what node set is involved.


Daniel Veillard      | Red Hat Network  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]