XML Mixed Content

XML > XML Mixed Content

An element type has mixed content when elements of that type may contain character data, optionally interspersed with child elements.] In this case, the types of the child elements may be constrained, but not their order or their number of occurrences:

In simple terms an element may contain text and other elements

Sample Copy Code
<description>character data <br/> more text <br/> and <strong>more data</strong></description>

Mixed content is a very effective way of marking up textual data, the most obvious example being HTML.

However it should only be used when the data is appropriate (typically some kind of marked up textual data), as it complicates the parsing application, and without putting significant work into the parser its possible to create constructs that are not interpreted correctly or uniformly, again see HTML!

As CDATA, Character and Entity References are expanded as normal within the element.

Try Liquid XML Free and see how we can help you today Free Trial