In XSLT, you can use wildcard expressions such as * and @* to process all the elements and attributes in an XML document. Use of these expressions allows us to apply this stylesheet to any XML document, regardless of the tags it uses. Because we use these wildcard expressions, we have to use the name( ) function to get the name of the element or attribute we’re currently working with.
<xsl:template match="*">
<xsl:variable name="element-name">
<xsl:value-of select="name()"/>
</xsl:variable>
...