Hi Martin, Hi List. I would like bump this mail up again, because I have nearly the same problem. Special characters like the german Ä,Ü,Ö are somehow affecting the tcp communication between service and client. Which leads to the general question: How can the char set encoding of a soap transmission be altered?
Thanks in advance and best regards Martin Benedix Am 14.01.2010 17:26, schrieb Martin Voelkle:
Hi list, I am writing a service client using Axis2/C 1.6 (win32 binary distribution) and WSDL2C, but I have a few issues: I am only sending numerical values, but the reply contains text nodes with non-ASCII characters. When the reply is deserialized in the generated code, the first element containing non-ASCII chars is empty and any following element is missing, a bit like the description in issue AXIS2C-1265. Looking through tcpmon, I see that both the request and the reply are UTF8, so I first tried to change this with the following code: axis2_options_t* options = axis2_stub_get_options(stub, env); axutil_property_t* charset = axutil_property_create(env); axutil_property_set_value(charset, env, "Windows-1252"); axis2_options_set_property(options, env, "CHARACTER_SET_ENCODING", charset); and: axis2_options_set_property(options, env, "CHARACTER_SET_ENCODING", "Windows-1252"); But none of these have any effect on the outgoing message or the reply deserialization (I also tried ISO-8859-1). I tried to set the Accept-Charset HTTP header using axis2_options_set_http_headers, which is sent correctly, but the service still replies using UTF-8. I added a Content-Type HTTP header (application/soap+xml;charset=Windows-1252;action="urn:action") and the service finally replied using a Windows-1252 charset. This has 2 problems: - the Content-Type HTTP header is sent twice, once set by me (with the Windows-1252 charset) and once set by Axis2/C (with the UTF-8 charset). I guess that I am lucky that my header is sent first. - the original problem is not solved, as the deserialization still has the same bug as with UTF-8! Is there an other way to override the outgoing charset? Is there a way to receive non-ASCII characters? Thank you, Martin Voelkle
--------------------------------------------------------------------- To unsubscribe, e-mail: c-user-unsubscr...@axis.apache.org For additional commands, e-mail: c-user-h...@axis.apache.org