saxonica.com

xsl:processing-instruction

The xsl:processing-instruction element can appear anywhere within an xsl:template. It causes an XML processing instruction to be output.

There is a mandatory name attribute which gives the name of the PI. This attribute is interpreted as an attribute value template, so it may contain string expressions within curly braces.

The data part of the PI may be given either by a select attribute or by an enclosed sequence constructor. If the select attribute is used and the value is a sequence, then the items in the sequence are output space-separated.

For example:

<xsl:processing-instruction name="submit-invoice">version="1.0"</xsl:processing-instruction>

Note that special characters occurring within the PI text will not be escaped.

Next