I am using following code to upload image to server,it is successfully uploaded but image orientation changing with -90.
I didnt understand how to solve this issue. My image in Sdcard is in correct orientation but I didnt get to know why this image changes its orientation.
HttpClient httpClient = new DefaultHttpClient();
HttpContext localContext = new BasicHttpContext();
HttpPost httpPost = new HttpPost(image_upload);
Log.e("strImagePath.... before uploading", al_image_paths.get(i));
multipartContent.addPart("image", new FileBody(new File(al_image_paths.get(i))));
multipartContent.addPart("sellleadid", new StringBody("2234"));
multipartContent.addPart("action", new StringBody("Send Used Car Images"));
multipartContent.addPart("app_id", new StringBody("1"));
totalSize = multipartContent.getContentLength();
httpPost.setEntity(multipartContent);
HttpResponse response = httpClient.execute(httpPost, localContext);
String serverResponse = EntityUtils.toString(response.getEntity());
Log.e("serverResponse image", "<> " + serverResponse);