getting high resolution photos that were posted on a page wall/feed

后端 未结 5 979
你的背包
你的背包 2020-12-15 09:58

I\'m getting my page wall with the open graph. And when someone posted a photo, I get it on the JSON

{
     \"id\": \"27888702146_10150369820322147\",
     \         


        
5条回答
  •  春和景丽
    2020-12-15 10:15

    Use this Code. Its Work for me and get Clear Image

    String PICTURE_URL;
    
    String getPicture = hashMap.get("picture");
            if (getPicture.contains("_t.")) {
                PICTURE_URL = getPicture.replaceAll("_t.", "_n.");
            } else if (getPicture.contains("_a.")) {
                PICTURE_URL = getPicture.replaceAll("_a.", "_n.");
            } else if (getPicture.contains("_s.")) {
                PICTURE_URL = getPicture.replaceAll("_s.", "_n.");
            } else if (getPicture.contains("_q.")) {              
                PICTURE_URL = getPicture.replaceAll("_q.", "_n.");
            }
            url=new URL(PICTURE_URL);
            Bitmap bitmap=BitmapFactory.decodeStream(url.openConnection().getInputStream());
            ((ImageView)view.findViewById(R.id.imageView_FullImage)).setImageBitmap(bitmap);
    

提交回复
热议问题