My solution is:
// ---Connects using HTTP GET---
public static InputStream OpenHttpGETConnection(String url) {
InputStream inputStream = null;
try {
HttpClient httpclient = new DefaultHttpClient();
HttpResponse httpResponse = httpclient.execute(new HttpGet(url));
inputStream = httpResponse.getEntity().getContent();
} catch (Exception e) {
Log.d("InputStream", e.getLocalizedMessage());
}
return inputStream;
}