Element with both attributes and name generated

Task: Generate element with run-time generated name, attribute names, value...

How-to: Use xsl:element:

<generate element="elt_name"> ... </generate> 

Šablona:

<xsl:template match="generate"> 
   <xsl:element name="{@element}">
      <xsl:attribute name="id">ID1</xsl:attribute>
   </xsl:element>
</xsl:template> 

Creates element elt_name with attribute id="ID1" .