This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: Getting the XPath of a node
- From: Jarno dot Elovirta at nokia dot com
- To: <xsl-list at lists dot mulberrytech dot com>
- Date: Wed, 4 Sep 2002 12:24:34 +0300
- Subject: RE: [xsl] Getting the XPath of a node
- Reply-to: xsl-list at lists dot mulberrytech dot com
Hi,
> Is there any way to get the XPath of a particular
> element and attribute in match template???
>
> Say if I have following XML:
> <Person id="12345">
> <Name>Dennis</Name>
> <Company>Netscape</Company>
> <Address>Mountain View</Address>
> <Email>dennis@netscape.com</Email>
> </Person>
>
> ----The XSL to print XPath---
> <xsl:template match="Company">
> //Print the XPath of Company as /Person/Company
> </xsl:template>
> More templates corresponding to each element.
>
> How do I do this...any thoughts???
See http://xsltsl.sourceforge.net/
Cheers,
Jarno
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list