Extension Elements

Extension elements are just what they sound like—elements that have been added to XSLT by the user or vendor. The XSLT 1.1 working draft set up some rules for extension elements, and XSLT 2.0 is supposed to go into a lot more depth on them. In the XSLT 1.1 working draft, the rules were that extension elements must be elements that are user-defined or vendor-defined, but are not top-level elements. And they must belong to a namespace that has been defined as an extension namespace.

You define an extension namespace by using the extension-element-prefixes attribute in an <xsl:stylesheet> element or an xsl:extension-element-prefixes attribute in a literal result element or extension element.

Here’s an example. Xalan enables you ...

Get Inside XSLT now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.