Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why are null char disallowed even in CDATA sections?

Tags:

null

xml

cdata

XML, Why are null char disallowed even in CDATA sections?

It seems to terminate the file right there.

Any solution? Base64?

like image 906
Robin Rodricks Avatar asked Sep 19 '25 01:09

Robin Rodricks


1 Answers

Because it's no valid XML character, ie it should produce a parse error. This is likely because of historical reasons (null terminated strings) and because of XML's plain-text nature: Anything on which a Unicode-capable editor might choke is discouraged...

like image 61
Christoph Avatar answered Sep 23 '25 12:09

Christoph