次の方法で共有


xsl:processing-instruction Element (Windows Embedded CE 6.0)

1/6/2010

Generates a processing instruction in the output.

Syntax

<xsl:processing-instruction
  name = "pi-name">
</xsl: processing-instruction>

Attributes

  • name
    [required] Name of the processing instruction.

Element Information

Number of occurrences

Unlimited

Parent elements

xsl:attribute, xsl:comment, xsl:copy, xsl:element, xsl:for-each, xsl:if, xsl:otherwise, xsl:param, xsl:template, xsl:variable, xsl:when, xsl:with-param, output elements

Child elements

xsl:apply-templates, xsl:call-template, xsl:choose, xsl:copy, xsl:copy-of, xsl:for-each, xsl:if, xsl:text, xsl:value-of, xsl:variable, output elements

Remarks

The <xsl:processing-instruction> element generates a processing instruction in the output. The name is indicated by the name attribute. The content of the element provides the rest of the processing instruction.

Example

This example shows a template that generates the XML declaration and a style sheet processing instruction in the output.

<xsl:template match="/">
  <xsl:text disable-output-escaping="yes">&#60;&#63;xml version="1.0"&#63;&#62;</xsl:text>
  <xsl:apply-templates />
</xsl:template>

See Also

Reference

XSLT Elements

Concepts

Generating More Sophisticated XML Output