Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Two XSLT 1.0 attributes that might allow you to accomplish what you want are:
This XSLT element tells the XSLT processor to always output text nodes within documentation elements as CDATA sections. Hence, with this <xsl:output> element and the template:
<xsl:template match="documentation">
<xsl:copy>
<xsl:apply-templates/>
</xsl:copy>
</xsl:template
your original example would be output as itself:
<documentation><![CDATA[<p>Some text</p>]]></documentation>
It gets more complicated if you want to illustrate CDATA sections in your documentation element.
tells the processor to output those special characters that are interpreted by an XML parser as themselves instead of as one of the XML representations of those characters. Thus, you can try:
<xsl:template match="documentation">
<xsl:copy>
<xsl:value-of disable-output-escaping="yes" select="."/>
</xsl:copy>
</xsl:template
Copy link to clipboard
Copied
Find more inspiration, events, and resources on the new Adobe Community
Explore Now