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

Re: EXPAT - XML parsing issue



You mean you put "iso-8859-1" in the processing instructions of your XML file, and the response from the web service said "utf-8" in it's processing instructions? I don't see how that would create the situation you describe. The one you send in the request is not used at all by HTTPAPI, it simply sends it as-is, and doesn't care what's in it. The response being UTF-8 is extremely common (in fact is is THE most common situation) and if Expat didn't recognize it, you'd get an error, not garbage.

Maybe someone changed the settings for the XML translation? Or maybe you have an old, outdated version of Expat on your system that it is picking up instead of the current one?


On 11/8/2016 5:07 PM, David Lynch wrote:
Hi Scott,

Thanks for your prompt reply. On the V5R4 machine I get the same problem with any of the example programs in LIBHTTP.

On the v5r4 machine I installed the suite of programs as per your readme file, using the option to use the pre-compiled expat program (as I have no QSYSINC so the compile was failing). On V6R1 I used the install option that compiled the expat.

I haven't had time to try to understand the complexities of the various programs used by this tool so I can't quite understand why the log file shows the returned XML in readable format, but the parser doesn't. Could be be something to do with the encoding? In the soap request I use encoding "iso-8859-1" but the encoding in the xml in the log file is "utf-8". This is identical on the two servers but it's just the V5R4 one that doesn't work.

Cheers


-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------