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

RE: R: CCSID problem?????



Hi Stefano,

I am HTTPAPI to call a Java based web service. I am sending an xml file to the web service and successfully using

http_setCCSIDs(1208 : 0);  // 1208 = UTF-8 

to convert the data to UTF-8 before calling http_url_post_xml.

I haven't followed the whole discussion but did you make sure that the characters are really correctly written to stream file? Did you try to download the file to your PC f. e. and check if it is really readable? I had my problems with that once. CCSID is really a beast that is hard to tame =)

Regards

Mihael


-----Original Message-----
From: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx [mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Scott Klement
Sent: Tuesday, April 05, 2011 11:38 AM
To: HTTPAPI and FTPAPI Projects
Subject: Re: R: CCSID problem?????

On 4/5/2011 2:22 AM, Stefano Busolo wrote:
> Thank you, Scott!
> I tryed to set the character set to ISO-8859-1, but the WS has received ? ? ? instead of ç à è.
> I attached the log.

Err..  I don't see why it'd have ? characters!  Unless that's something 
the web service is doing on the other end?

>
> Is it possible that the WS accepts only UTF-8?
>

Sure, it's possible.  I don't know if it's the case or not, since I 
don't run the web service you're connecting to.



> Must I use the "HTTP_SetCCSIDs(xxx: 0)" before of "rc = http_url_post_xml(  ...)"??

Yes, that's how you control the CCSID that your data is translated into.



>
> When I call the WS, the request is the same that I see in senddoc() tag of the log file???
>

Yes, the POST data sent with your request is written to the debug file 
as-is (after it has translated it.)   So the data in the log file is 
byte-for-byte what you are sending to the web service.

However, depending on how you're viewing the debug file, your viewer may 
be translating it (or mistranslating it)...
-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------
-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------