This is something of an XML FAQ...

Most of these characters are not legal in XML, and there really is no way
to represent them directly. Even numeric character references won't get you
past this restriction.

The standard workaround is to replace them with some other representation.
There really isn't a single best answer;  what's easiest for one
application is not necessarily easiest for another. For arbitrary binary
data, I'd suggest using base-64, as MIME did. If these are just isolated
control characters in text, you might want to consider swiping the kind of
escape sequences used  by other systems -- eg, the \ escapes used in
Java/C/C++, or the # escapes sometimes used in URIs. That does require that
you preprocess the existing data into this form, and convert it back later,
and of course you have to be prepared to escape whatever character
introduces the escapes if it ever arises in your input data.

So yes, people have solved this one, but you have to pick which solution
makes sense for you.



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to