cmour
cmour

Reputation: 598

BlackBerry Web-service call parameter encoding

I have used the Java Sun Wireless Toolkit 2.5.2 to generate method stubs for my SOAP webservice. I have been using this for a while and it works great. I now need to add support for the French language. When I send up a string like 'pièce' as one of the properties on an object, it turns into 'pi??ce' by the time it is read by the server. Obviously, the encoding is off somewhere, but I can't see anywhere that I can change the way the generated stub encodes the parameters passed to the web service. Any suggestions?

Update: Here is the header and the start of the xml sent from the BlackBerry:

POST /website/service.asmx HTTP/1.1
Connection: close
Via: MDS_4.1.5.26
Content-Length: 2257
Content-Type: text/xml
Content-Language: en-US
Accept: */*
Host: host
User-Agent: RIM JSR172/1.0
SOAPAction: "http://www.test.com/Test"

<?xml version="1.0" encoding="utf-8"?>

Here is the header and the start of the xml sent from the iPhone (which works):

POST /website/service.asmx HTTP/1.1
Connection: keep-alive
Content-Length: 2359
Content-Type: application/soap+xml; charset=utf-8
Accept: */*
Accept-Encoding: gzip, deflate
Accept-Language: fr-fr
Host: host
User-Agent: wsdl2objc
Soapaction: http://www.test.com/Test

<?xml version="1.0"?>

Upvotes: 3

Views: 525

Answers (1)

Scott Hanselman
Scott Hanselman

Reputation: 17702

There is a Unicode BOM? I'd check the packet sniffer. As it may not be the content-type but rather the bytes themselves.

Upvotes: 1

Related Questions