Page 1 of 1
preventing processing of codeblock
Posted: Tue Nov 02, 2010 9:28 pm
by sgrayson
How do I prevent Oxygen from processing XML code in a codeblock element? I want to be able to put anything in the codeblock, but currently Oxygen is requiring that I use escape characters for left bracket and ampersand.
Steven Grayson
Re: preventing processing of codeblock
Posted: Tue Nov 02, 2010 9:41 pm
by george
It is not a requirement of oXygen, it is an XML requirement. You cannot enter < and & directly in a text, you need to XML escape that. You can use a CDATA section and inside that you can enter < and & without escaping. So for example instead of
Code: Select all
<codeblock>Sample text containing < and &</codeblock>
you can write
Code: Select all
<codeblock><![CDATA[Sample text containing < and &]]></codeblock>
Hope that helps,
George
Re: preventing processing of codeblock
Posted: Tue Nov 02, 2010 11:43 pm
by sgrayson
Thank you, George! That's exactly what I was looking for. I built the project as both pdf and html and the code can still be copied successfully without being pasted as a comment. I appreciate the help!
Steven Grayson