I am trying to print an XML file "AS-IS" i,e. with tags into PDF using Apache FOP. I am started with ExampleXML2PDF example file in src dir of FOP 1.1. I am able to print formatted XML objects, not able to print XML with tags.
XSL is as below,
<xsl:stylesheet version="2.0" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:param name="testRaw" />
<xsl:template match="/">
<fo:root>
<fo:layout-master-set>
<fo:simple-page-master master-name="my-page">
<fo:region-body margin="0.5in" />
</fo:simple-page-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="my-page">
<fo:flow flow-name="xsl-region-body" font="7pt Times">
<fo:block break-before="page">
<xsl:value-of select="$testRaw" />
</fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>
</xsl:template>
Java code used to set parameters.
CDATA
. If you give an example of your XSLT where you're trying to output literal XML, I can add show you. – Daniel Haley