[xml] Encoding problems



Hello,
I generate a xmlfile as normal ASCII Textfile with some special characters like äöü... To parse it with xmlreader I have to use the line <?xml version="1.0" encoding="ISO-8859-1"?>
Internally the parse use allways UTF-8. Right?

When I access text or attributevalues I have to do extra conversion with function I found with xmlFindCharEncodingHandler(...). Is there no better way? I can set encoders e.x. in xmlReaderForMemory(...) but it hasn't any effect.

When I extract xmlfragments with xmlTextReaderReadOuterXml(...) I must do a double conversion (2 x UTF-8 to ISO-8859-1) to get the right text. It is very expensive. Is there a way to tell the parser to do this and give me the right text (normal ascii string like in the file) ?

thanks for help

lars




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]