so far as I know, the default encoding of  "UTF-8" is used(using a
sniffer to capture the request), below is my code:

HttpClient httpClient = getNewHttpClient();

PostMethod postMethod = new PostMethod(formBaseUrl);

postMethod.addRequestHeader("Referer", refererBaseUrl);
postMethod.addRequestHeader("User-Agent", "Mozilla/4.0 (compatible;
MSIE 6.0; Windows NT 5.2; Maxthon; .NET CLR 1.1.4322)");

NameValuePair uin = new NameValuePair("UIN", id);
NameValuePair verify = new NameValuePair("VERIFY", key);
postMethod.setRequestBody(new NameValuePair[] {uin, verify});

The "VERIFY" may contain multibytes characters(Chinese), and the
server only accepts it in specified encoding(GB2312). I have googled a
lot and read the mannual and tried hard, but still failed to make it
work with other encodings. Any solution to this?

Thanks in advance! Good day :-)

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to