Re: [xsl] [XSLT2] setting context inside funcdefs

Subject: Re: [xsl] [XSLT2] setting context inside funcdefs
From: Tobias Reif <tobiasreif@xxxxxxxxxxxxx>
Date: Fri, 14 Feb 2003 16:03:52 +0100
Hi Jeni

Possibly it's referring to the fact that the focus can be set within a
particular variable declaration. For example, the function might

  <xsl:variable name="path">
    <xsl:for-each select="$context/ancestor-or-self::*">
      <xsl:value-of select="local-name()" />

Within the <xsl:for-each> the focus would be defined as usual and the
local-name() function can be used without an explicit argument.

Yep, I also thought of that ... but stopped when I started thinking about wrapping large parts of the funcdef in one big for-each (with one iteration), just to save some typing ;)

Perhaps it would be handy to have some focus-setting wrapper or attribute for use inside function definitions ... like base-url.



XSL-List info and archive:

Current Thread