xsl-list
[Top] [All Lists]

Re: accessing attributes from different contexts

2003-01-20 12:19:19
Claude Montpetit wrote:
Considering the following xsl code

<xsl:template match="elem[(_at_)attrib]">
  <xsl:variable name="attrib" select="@attrib"/>
  <xsl:value-of select="$otherDoc/otherElem[(_at_)attrib=$attrib]"/>
</xsl:template>

, is there a way to compare the "attrib" attribute of the template's
context node to the one in the otherDoc xpath expression without
creating a variable? If the above approach the best way to do this?

<xsl:value-of select="$otherDoc/otherElem[(_at_)attrib=current()/@attrib]"/>

--
Oleg Tkachenko
eXperanto team
Multiconn Technologies, Israel


XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>