retrieving information from a parent node
How can I retrieve the attributes(the complete tag) of a parent node while I'm at one of it's childs?
Ive tried various xpath expression but none worked.
My problem is the following:
INPUT xml
---------
<a a1=1 a2=0>
<b> </b>
<b> </b>
<b> </b>
<a/>
XSLT
----
<xsl:template match = "a" >
<xsl:for-each select="b">
<!-not related code-->
<!-- in this point I have to do: <xsl:copy-of select="@*"/>
(output -> <a a1=1 a2=0> )-->
</xsl:for-each>
</xsl:template>
Thanks.
Tomi.
|