I want to get an attribute from another element.
E.g.
<xsl:template match="tag1">
Test: <xsl:value-of select="inner[@class='test']@name"/>
</xsl:template>
XML:
<xml>
<tag1>
<inner class="something" name="123"/>
<inner class="test" name="456"/>
</tag1>
</xml>
So what I'm expecting is to get
Test: 456
Obviously the XSLT above doesn't work, but that's what it should logically be. Can someone help me?
Thanks