HttpURLConnection conn = (HttpURLConnection) url.openConnection(); conn.setReadTimeout( 15000 ); conn.setConnectTimeout( 15000 ); conn.setRequestMethod( "POST" ); conn.setDoInput( true ); conn.setDoOutput( true ); OutputStream os = conn.getOutputStream(); BufferedWriter writer = new BufferedWriter( new OutputStreamWriter(os, "UTF-8" )); String paramStr = null ; {// need BasicNameValuePair -> ContentsValue for (BasicNameValuePair record : params ){ if (paramStr == null ){ paramStr = "" ; } else { paramStr = paramStr + "&" ; } paramStr = paramStr + record.getName()+ "=" +record.getValue(); } } writer.write(paramStr); writer.flush(); writer.close(); os.close(); int responseCode=conn.getResponseCode(); if (responseCode == HttpsURLConnection. HTTP_OK ) { String line; BufferedReader br= ...