Reputation: 311
I am using Java digester for reading XML. My XML element has some HTML contents like:
<title> Understand the following as special cases:<br/>a. Bundle of ten ones — called a "ten."<br/>b. The numbers from 11 to 19 are composed of a ten and one, two, three, four, five, six, seven, eight, or nine ones.<br/>c. Recording the results of comparisons with the symbols >, =, and <.</title>
After parsing it is changed like below.
Understand the following as special cases: <br/>a. Bundle of ten ones — called a "ten." <br/>b. The numbers from 11 to 19 are composed of a ten and one, two, three, four, five, six, seven, eight, or nine ones.<br/>c. Recording the results of comparisons with the symbols >, =, and <.
I want to read or parse as it is.
Upvotes: 0
Views: 106
Reputation: 272347
That's not properly formed XML. For example:
Recording the results of comparisons with the symbols >, =, and <
should use the XML entities <
and >
So an XML parser will fail against this.
Upvotes: 1