Created
August 6, 2013 14:40
-
-
Save smaspe/6165095 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JSONObject response = new JSONObject(EntityUtils.toString( | |
new DefaultHttpClient().execute( | |
new HttpGet(params[0])).getEntity(), "UTF-8")); | |
if (response.optBoolean("success", false)) { | |
return response.getJSONObject("response").getJSONArray("photos"); | |
} else { | |
Log.w(TAG, "Request failed. Details: " + response.toString(2)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment