XSLT - Advanced elements

 


Advanced elements

The elements in this section round out the set of XSLT elements. These elements are used less often but may be helpful in certain cases.

xsl:apply-imports: Use an overridden template

You can use templates that you have imported using the xsl:import tag, but you can also override them by providing your own template. The <xsl:apply-imports/> tag allows you to use an imported template even if you have overridden it.

There are no attributes and no content. The template you are invoking is the one overridden by the current template.
xsl:attribute-set: Define a named attribute set

Often you will want to add one or more attributes to an element you are generating with the xsl:element tag. The xsl:attribute-set element lets you create a named set of attributes so you can add them merely by referring to that name with the use-attribute-sets attribute of xsl:element.

Use one or more xsl:attribute children as the content of this element. Those attributes and their values make up the attributes in the set.

Attributes of xsl:attribute-set include:

name (required)

    Gives this attribute set a name.
use-attribute-sets

    Any attribute sets named in this value become part of the attribute set you are creating.


     xsl:apply-imports: Use an overridden template
     xsl:attribute-set: Define a named attribute set
     xsl:comment: Output a comment
     xsl:copy: Shallow copying
     xsl:copy-of: Deep copying
     xsl:fallback: What to do if an extension is missing
     xsl:message: Write a debugging message
     xsl:namespace-alias: Assign a prefix to a namespace
     xsl:processing-instruction: Output a processing instruction
     xsl:sort: Process nodes in a given order
 

 

 

source: http://infohost.nmt.edu/~shipman/doc/xslt/web/advanced-elts.html