http://localhost:8080/im;” + “jsessionid=”
to make a post connection
HttpURLConnection httpURLConnection =(HttpURLConnection)url.openConnection();httpURLConnection.setUseCaches(false);httpURLConnection.setDoOutput(true);httpURLConnection.setDoInput(true);httpURLConnection.setRequestMethod(“POST”);httpURLConnection.setRequestProperty(“Content-Type”,”application/x-www-form-urlencoded”);StringBuffer sbContent = new StringBuffer();sbContent.append(…);DataOutputStream stream = newDataOutputStream(httpURLConnection.getOutputStream ());stream.writeBytes(sbContent.toString());stream.flush();stream.close();InputStream inputStream =httpURLConnection.getInputStream();inputStream.close();