[ https://issues.apache.org/jira/browse/AXIS2-1575?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Davanum Srinivas resolved AXIS2-1575. ------------------------------------- Resolution: Fixed Fix Version/s: (was: 1.3) > Axis2 does not decodes SOAP responses using the character encoding set on the > response's XML declaration. Problem converting from iso-8859-1 to utf-8. > ------------------------------------------------------------------------------------------------------------------------------------------------------ > > Key: AXIS2-1575 > URL: https://issues.apache.org/jira/browse/AXIS2-1575 > Project: Axis 2.0 (Axis2) > Issue Type: Improvement > Affects Versions: 1.0 > Environment: Windows XP + java 1.5 + axis2 1.0. I'm using client-side > axis2 code. no server-side axis is involved. > Reporter: Bruno Negrao > Assignee: Deepal Jayasinghe > Priority: Blocker > > My SOAP server (it isn't axis2 based) sends SOAP responses like this one > shown at the end of this message. > The soap server does not set the 'Content-type' http header as was expected > so it's not possible to get the charset used in the response body from that. > But the server defines the character encoding on the response's XML > declaration, example: > <?xml version="1.0" encoding="iso-8859-1"?> > Axis2 is ignoring the character enconding defining on the XML declaration and > is decoding all the strings sent as if they were UTF-8. > The result is I cannot display the words correctly here on the client-side. > The OMElement.getText() method returns crazy utf-8 characters instead of my > latin characters (like á ó ç ã ê, etc). > I proved that axis2 uses utf-8 to decode the network inputstream when I ran > the following method on the OMElement returned as response: > response.getXMLStreamReader().getCharacterEncodingScheme() > It returns 'utf-8' and it should return 'iso-8859-1'. Not only it returns > utf-8 but it is indeed using utf-8 to decode the inputstream, what is wrong > for this situation. > The improvement I'm asking here is update axis2 so it obey to the encoding > definition on the response's XML declaration. > thank you, > bruno. > **************************************************************************************** > AN EXAMPLE OF A SOAP RESPONSE SENT FROM MY SOAP SERVER: > **************************************************************************************** > HTTP/1.0 200 OK > Content-length: 1269 > <?xml version="1.0" encoding="iso-8859-1"?> > <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> > <soap:Body> > <AgendaPesquisa> > <status>0</status> > <ListaContatosPesquisa> > <tipo>C</tipo> > <dono>lucia</dono> > <posicao>177</posicao> > <nome>Abricó Gimarães</nome> > <email></email> > </ListaContatosPesquisa> > </AgendaPesquisa> > </soap:Body> > </soap:Envelope> -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]