Michael, > I'm sorry to say that while I can't provide you with a solution, I can > at least verify that something is going wrong with the unicode strings.
Good, at least it isn't me then. > However, in my tests (Mac OS 10.3.7 and libxml 2.2.6 with XML::LibXML > 1.58) I am getting well-formed XML in both output. I will try 2.2.6 and see what happens. >Using your example, > I have verified that while toFile properly displays: > > <?xml version="1.0" encoding="utf-8"?> > <MSG>*Ä*</MSG> A hexdump should show two bytes between the asterisks, C3 and 84. > when I changed your code to print the result of toString to a file, I > got > > <?xml version="1.0" encoding="utf-8"?> > <MSG>*?*</MSG> toString decodes the utf8 to hex C4. > What versions of Perl and XML::LibXML/libxml2 are you running? (Note: > I'm very much a noob when it comes to unicode) libxml 2.5.11 XML::LibXML 1.57 I have just upgraded to libxml 2.6.17 and XML::LibXML 1.58. It still breaks. It isn't a major problem, I will either have to use toFH with *STDOUT or write my own toString. As it happens I will have to do the latter anyway because of legacy code that sort of reads xml :) I am curious as to what causes it tho, I do so hate loose ends. Thx for your time. John --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]