Facebook GRAPH API照片如无分页计数 [英] Facebook GRAPH API Photo like count without paging

查看:177
本文介绍了Facebook GRAPH API照片如无分页计数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试像FB图片一样。我们计算的喜欢的图片通常非常受欢迎,所以有很多LIKES。



例如,4年多的奥巴马图片是最多喜欢在Facebook上有超过400万的喜欢。



问题是GRAPH API中的任何地方都不能得到这个数字,我必须通过整个四百万的喜欢的页面获得数字...它的疯狂。



https://graph.facebook.com/10151255420886749/likes

  {
data:[
{
id:100004002885259,
name:Camy Doyna
},
{
id:100003495050210,
name:Louzoco de Carvasal
},
{
id:536183064,
name:Emily Brearley
},
{
id:100002742193990,
name:Rosette Gracia Moukengue
},
{
id:100001107540696,
name:Pac\\\ôme Chazelle
$,
{
id:100001035425365,
name:Niklas Pulli
},
{
id :100003292089993,
name:Barbara Grimm
},
{
id:642830020,
name:Elin
},
{
id:100000718890127,
name:Katya Katyusha
},
{
id:1644725575,
name:Lara Corti
},
{
id:100002024205882,
名称:Garibyan Anna
},
{
id:100002159247248,
name:Marcos Fernando
},
{
id:1725354804,
name:Kevin Burk
},
{
id:1524833123,
name:Roberto TwoHands Bertuccelli
},
{
id:1056165559,
name:Arman Hossain Anand
},
{
id:1052974324,
name:Kathy Johng Shelton
$,
{
id:100000254736003,
name:Tina Mosely
},
{
id :595281527,
name:Kim Fontaine-Skronski
},
{
id:100002935725139,
name Iulian Boxerul
},
{
id:100001450004383,
name:Nora Lachgar
},
{
id:100001859484728,
name:Joan Breen
},
{
id:1802479070,
name:Jan Meyer
},
{
id:1815802454,
name:Gregor y Nobre
},
{
id:100002988798465,
name:Aika JU
},
{
id:100003737463206,
name:Ingrid Theiszov \\\á-Bajusov \\\á
}
],
paging {
next:https://graph.facebook.com/10151255420886749/likes?limit=25&offset=25&__after_id=100003737463206
}
}
https: //graph.facebook.com/10151255420886749

  {
id:10151255420886749
from:{
category:Politician,
name:Barack Obama,
id:6815841748
} ,
name:四年以上,
picture:http://photos-a.ak.fbcdn.net/hphotos-ak-ash4/409202_10151255420886749_2117448131_s.jpg
source:http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s720x720/4 09202_10151255420886749_2117448131_n.jpg,
height:478,
width:720,
images:[
{
height:1359,
width:2048,
source:http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s2048x2048/409202_10151255420886749_2117448131_n.jpg
}
{
height:532,
width:800,
source:http://sphotos-a.ak.fbcdn.net/hphotos- ak-ash4 / 409202_10151255420886749_2117448131_n.jpg
},
{
height:478,
width:720,
source:http: //sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s720x720/409202_10151255420886749_2117448131_n.jpg
},
{
height:398,
宽度:600,
源:http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s600x600/409202_10151255420886749_2117448131_n.jpg
},
{
height:318,
width:480,
source:http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s480x480/409202_10151255420886749_2117448131_n.jpg
},
{
height:212,
width:320,
source:http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s320x320/409202_10151255420886749_2117448131_n.jpg
},
{
height:119,
width:180,
source:http://photos-a.ak .fbcdn.net / hphotos-ak-ash4 / 409202_10151255420886749_2117448131_a.jpg
},
{
height:86,
width:130,
source:http://photos-a.ak.fbcdn.net/hphotos-ak-ash4/409202_10151255420886749_2117448131_s.jpg
},
{
height:86,
width:130,
source:http://photos-a.ak.fbcdn.net/hphotos-ak-ash4/s75x225/409202_10151255420886749_2117448131_s.jpg
}
],
link:http://www.facebook.com/photo.p hp?fbid = 10151255420886749& set = a.53081056748.66806.6815841748& type = 1,
icon:http://static.ak.fbcdn.net/rsrc.php/v2/yz/r/
created_time:2012-11-07T04:15:07 + 0000,
updated_time:2012-11-07T04:15:07 + 0000,
comment:{
data:[
{
id:10151255420886749_12810477,
from:{
name :David Carol,
id:100003175318626
},
消息:BISHOP ZACHARY KAKOBE在其部门验证的艾滋病健康模拟器。该网址:WWW.bishopzacharykakobe.org,
can_remove:false,
created_time:2012-11-28T20:00:21 + 0000,
like_count:0,
user_likes:false
},
{
id:10151255420886749_12811019,
from:{
name:Lievin Bangali,
id:1812106678
},
message:Barack Obama,Felicitation de votre reelection。刚果民主共和国的事态发展。 Merci et courage!,
can_remove:false,
created_time:2012-11-28T20:40:28 + 0000,
like_count:0,
user_likes:false
},
{
id:10151255420886749_12811211,
from:{
name:Pamela Aupindi ,
id:100004586432226
},
消息:奥巴马总统不仅是一个有魅力的领导人,而且是一个显然富有激情的人。可以通过图片感受到他妻子的爱!惊奇
can_remove:false,
created_time:2012-11-28T20:54:40 + 0000,
like_count:1,
user_likes:false
},
{
id:10151255420886749_12811850,
from:{
name:Ardavan Shafiie,
id:1174217484
},
message:graet picture,
can_remove:false,
created_time 11-28T21:35:26 + 0000,
like_count:0,
user_likes:false
},
{
id 10151255420886749_12812793,
from:{
name:Samson Anifowose,
id:658496517
},
message 最好的!,
can_remove:false,
created_time:2012-11-28T22:51:30 + 0000,
like_计数:0,
user_likes:false
},
{
id:10151255420886749_12814187,
from:{
name:Yago Costa,
id:100000919886198
},
message:isso ae negao !!!,
can_remove :false,
created_time:2012-11-29T00:39:57 + 0000,
like_count:1,
user_likes:false
}
{
id:10151255420886749_12814238,
from:{
name:Sena Raharja,
id:100004587874401
},
message:wow,
can_remove:false,
created_time:2012-11-29T00:43:08 + 0000
like_count:0,
user_likes:false
},
{
id:10151255420886749_12814255,
from:{
name:Getachew Biratu,
id:100004104261949
},
message:Better \\\@
can_remove:false,
created_time:2012-11-29T00:43:45 + 0000,
like_count:0 ,
user_likes:false
},
{
id:10151255420886749_12814350,
from:{
name Bennydictus Ari Setiabudi,
id:714307966
},
message:uhuk ... lama2 terkikis image seno raharjo ... XD,
can_remove:false,
created_time:2012-11-29T00:50:10 + 0000,
like_count:0,
user_likes:false

$ bid:10151255420886749_12814615,
from:{
name:Sena Raharja
id:100004587874401
},
message:mukanya mirip gua。
can_remove:false,
created_time:2012-11-29T01:06:44 + 0000,
like_count:0,
user_likes:false
},
{
id:10151255420886749_12814662,
from:{
name Bennydictus Ari Setiabudi,
id:714307966
},
message:beda nasib dikit doang kali y ... hehehe ...:D,
can_remove:false,
created_time:2012-11-29T01:09:59 + 0000,
like_count:1,
user_likes:false
$,
{
id:10151255420886749_12814794,
from:{
name:Subhash Biradar,
id :100003474405756
},
消息:它更好...哈哈哈哈,
can_remove:false,
created_time:2012-11-29T01:20:35 + 0000,
like_count:0,
user_likes:false
},
{
id:10151255420886749_12815269,
from:{
name:Barbara J. Beverly,
id:1348022951
$,
message:我还在微笑和快乐....美国这么美好的一天,
can_remove:false,
created_time: 2012-11-29T01:51:15 + 0000,
like_count:0,
user_likes:false
},
{
id :10151255420886749_12815652,
from:{
name:Phillip Mason,
id:100001280178407
},
:让我想要吐出来穆斯林和他的..........,
can_remove:false,
created_time:2012-11-29T02:17:19 + 0000,
like_count:0,
user_likes:false
},
{
id:10151255420886749_12815699,
from:{
name:Jeremiah Bates,
id:100000912015322
},
message:我上面的小丑远远低于我,
can_remove:false,
created_time:2012-11-29T02:21:04 + 0000,
like_count:0,
user_likes:false
},
{
id:10151255420886749_12815758,
from:{
name:Jeremiah Bates,
id:100000912015322
},
message:悲伤...菲利普·梅森,他们有自助磁带,教育计划,支持组r未受过教育的傻瓜,如你自己....,
can_remove:false,
created_time:2012-11-29T02:26:12 + 0000,
like_count :0,
user_likes:false
},
{
id:10151255420886749_12816036,
from:{
名字:Romy Christie,
id:100003856980181
},
message:到Barbara J Beverly,我完全同意你的意思,美国长期以来的总统奥巴马,他的未来四年可能让他成为历史上闪闪发光的地方!伟大的魅力和一个伟大的演说家,我相信他在他第一次开始时,肩负沉重的沉重的负担,正在做最大的努力。从罗马,英国国民,永久居民在东京日本,2012年11月29日即时。
can_remove:false,
created_time:2012-11-29T02:45:35 + 0000,
like_count:1,
user_likes false
},
{
id:10151255420886749_12818055,
from:{
name:\\\Ģin \\\Ǿblsk\ u00e5 K\\\än\\\ĕ,
id:100001520690200
},
message:\\\ف\\\ى \\\ا\\\ي\ u0647 \\\ي\\\ل \\\و\\\ل\\\ا\\\د \\\ا\\\ل .........,
can_remove:false,
created_time:2012-11-29T06:37:20 + 0000,
like_coun t:1,
user_likes:false
},
{
id:10151255420886749_12818064,
from:{
name:Cm Amgad,
id:100001979501265
},
message:\\\ا\\\ن\\\ت\\\ا \\\ي \\\ا \\\ع\\\ا \\\ب\\\ا\\\ر\\\ا\\\ك \\\ا\\\و\\\ب\\\ا\\\م\\\ا,
can_remove :false,
created_time:2012-11-29T06:38:26 + 0000,
like_count:0,
user_likes:false
} ,
{
id:10151255420886749_12818067,
from:{
name:Cm Amgad,
id:100001979501265
},
message:\\\ل\\\م\\\ا \\\ا\\\ل\\\ا\\\س \u62B \\ u064a\\\ة \\\ك\\\س\\\ك\\\س\\\م\\\ك,
can_remove:false,
created_time:2012-11-29T06:39 :21 + 0000,
like_count:0,
user_likes:false
},
{
id:10151255420886749_12818275,
from:{
name:Denise Mutty Henry,
id:707184927
},
message:谁是老板?
can_remove:false,
created_time:2012-11-29T07:21:36 + 0000,
like_count:0,
user_likes:false
},
{
id:10151255420886749_12818295,
from:{
name:Steve Muguerza ,
id:100001926262266
},
消息:不要担心,亲爱的,我会像你说的那样做,并开始美国与美国帮助我,他们是如此的弱我们将派他们一张支票,让他们保持下去,就像我们保持黑色和他们的位置。 b $ bcan_remove:false,
created_time:2012-11-29T07:25:55 + 0000,
like_count:0,
user_likes:false
},
{
id:10151255420886749_12818637,
from:{
name:David Torrens,
id:699130216
},
message:所以美国投票选择合适的球队。还有我觉得你可能会回到一个比较粗暴的螺母。,
can_remove:false,
created_time:2012-11-29T08:48:22 + 0000,
like_count:1,
user_likes:false
},
{
id:10151255420886749_12818837,
from:{
category:虚构人物,
name:\\\م\\\ُ\\\ـ\\\س\\\ت\\\ح\\\ي\\\ـ\\\ـ\\ \ـ\\\ـ\\\ل \\\أ\\\ن\\\ـ\\\س\\\ـ\\\ـ\\\ـ\\\ـ\\\ا\\\ك\\\ي\\\ِ \\\ل\\\أ \\\ن\\\ن\\\ّ\\\ـ\\\ـ\\\ـ\\\ـ\\\ي \\\ع\\\ا\\\ي\\\ـ\\\ـ\\\ـ\\\ـ\\\ش\ u064c \\\ع\\\ل\\\ـ\\\ـ\\\ـ\\\ـ\\\ي \u06 30\\\ك\\\ـ\\\ـ\\\ـ\\\ر\\\ا\\\ك\\\ـ\\\ـ\\\ـ\\\ـ\\\ـ\\\ي\\\ِ,
id:101906399977956
},
message:http://www.facebook.com/pages/\\\%D9\\\%85\\\%D9\\\%8F\\\%D8\ u0025B3\\\%D8\\\%AA\\\%D8\\\%AD\\\%D9\\\%8A\\\%D9\\\%80\\\%D9\\\%80\\\%D9\\\%80\\\%D9\\\%80\\\%D9\\\%80\\ \%D9\\\%80\\\%D9\\\%84-\\\%D8\\\%A7\\\%D9\\\%86\\\%D8\\\%B3\\\%D9\\\%80\\\%D9\\\%80\\\%D9\\\%80\ u0025D9\\\%80\\\%D9\\\%80\\\%D8\\\%A7\\\%D9\\\%83\\\%D9\\\%8A-\\\%D9\\\%84\\\%D8\\\%A3\\\%D9\\\%86\\\%D9 \%86\\\%D9\\\%8A-\\\%D8\\\%B9\\\%D8\\\%A7\\\%D9\\\%8A\\\%D8\\\%B4-\\\%D8\\\%B9\\\%D9\\\%84\\\%D9\\ \%8A-\\\%D8\\\%B0\\\%D9\\\%83\\\%D8\\\%B1\\\%D8\\\%A7\\\%D9\\\%83\\\%D9\\\%8A / 101906399977956?ref = hl,
can_remove:false,
created_time:2012-11-29T09:36:54 + 0000,
like_count:0,
user_likes:false
$ b {
id:10151255420886749_12819093,
from:{
name:Mojisola Otu,
id :100000238597273
},
message:所有的Best.\\\
My家庭为您祷告,
can_remove:false,
created_time :2012-11-29T10:41:24 + 0000,
like_coun t:1,
user_likes:false
}
],
分页:{
next:https://graph.facebook .com / 10151255420886749 / comments?limit = 25& offset = 25& __ after_id = 10151255420886749_12819093
}
},
喜欢:{
data:[
{
id:100004002885259,
name:Camy Doyna
},
{
id:100003495050210
name:Louzoco de Carvasal
},
{
id:536183064,
name:Emily Brearley

{
id:100002742193990,
name:Rosette Gracia Moukengue
},
{
id:100001107540696,
name:Pac\\\ôme Chazelle
},
{
id:100001035425365,
名称:尼克拉斯拉我

{
id:100003292089993,
name:Barbara Grimm
},
{
id:642830020,
name:Elin Vinterhed
},
{
id:100000718890127,
名称:Katya Katyusha
},
{
id:1644725575,
name:Lara Corti
},
{
id:100002024205882,
name:Garibyan Anna
},
{
id:100002159247248
name:Marcos Fernando
},
{
id:1725354804,
name:Kevin Burk
},
{
id:1524833123,
name:Roberto TwoHands Bertuccelli
},
{
id :1056165559,
name:Arman Hossain Anand
},
{
id:1052974324,
name:Kathy Johng Shelton
} ,
{
id:100000254736003,
name:Tina Mosely
},
{
id 595281527,
name:Kim Fontaine-Skronski
},
{
id:100002935725139,
name:Iulian Boxerul
},
{
id:100001450004383,
name:Nora Lachgar
},
{
id:100001859484728,
name:Joan Breen
},
{
id:1802479070,
名称:Jan Meyer
},
{
id:1815802454,
name:Gregory Nobre
},
{
id:100002988798465,
name:Aika JU
},
{
id:100003737463206,
name :Ingrid Theiszov \\\á-Bajusov \\\á
}
],
分页:{
next:https://graph.facebook。 com / 10151255420886749 / likes?limit = 25& offset = 25& __ after_id = 100003737463206
}
}
}

做一些像添加一个极高值的分页限制参数的方法太慢了...有一种方法可以直接得到计数?

解决方案

您可以通过检索此信息照片 FQL表

 从照片中选择like_info object_id = 10151255420886749; 

返回:

 code> {
data:[
{
like_info:{
can_like:true,
like_count:4444816,
user_likes:false
}
}
]
}


I'm trying to get like counts for FB pictures. The pictures we are counting the likes for are usually VERY popular so have a big amounts of LIKES.

For example, the " 4 more years" obama picture is the "most liked" on facebook with more than 4 million likes.

The problem is that nowhere in the GRAPH API reponse for that picture do we get the count number, I would have to page through the whole four million likes to get the number... its insane.

https://graph.facebook.com/10151255420886749/likes

{
   "data": [
      {
         "id": "100004002885259",
         "name": "Camy Doyna"
      },
      {
         "id": "100003495050210",
         "name": "Louzoco de Carvasal"
      },
      {
         "id": "536183064",
         "name": "Emily Brearley"
      },
      {
         "id": "100002742193990",
         "name": "Rosette Gracia Moukengue"
      },
      {
         "id": "100001107540696",
         "name": "Pac\u00f4me Chazelle"
      },
      {
         "id": "100001035425365",
         "name": "Niklas Pulli"
      },
      {
         "id": "100003292089993",
         "name": "Barbara Grimm"
      },
      {
         "id": "642830020",
         "name": "Elin Vinterhed"
      },
      {
         "id": "100000718890127",
         "name": "Katya Katyusha"
      },
      {
         "id": "1644725575",
         "name": "Lara Corti"
      },
      {
         "id": "100002024205882",
         "name": "Garibyan Anna"
      },
      {
         "id": "100002159247248",
         "name": "Marcos Fernando"
      },
      {
         "id": "1725354804",
         "name": "Kevin Burk"
      },
      {
         "id": "1524833123",
         "name": "Roberto TwoHands Bertuccelli"
      },
      {
         "id": "1056165559",
         "name": "Arman Hossain Anand"
      },
      {
         "id": "1052974324",
         "name": "Kathy Johng Shelton"
      },
      {
         "id": "100000254736003",
         "name": "Tina Mosely"
      },
      {
         "id": "595281527",
         "name": "Kim Fontaine-Skronski"
      },
      {
         "id": "100002935725139",
         "name": "Iulian Boxerul"
      },
      {
         "id": "100001450004383",
         "name": "Nora Lachgar"
      },
      {
         "id": "100001859484728",
         "name": "Joan Breen"
      },
      {
         "id": "1802479070",
         "name": "Jan Meyer"
      },
      {
         "id": "1815802454",
         "name": "Gregory Nobre"
      },
      {
         "id": "100002988798465",
         "name": "Aika JU"
      },
      {
         "id": "100003737463206",
         "name": "Ingrid Theiszov\u00e1-Bajusov\u00e1"
      }
   ],
   "paging": {
      "next": "https://graph.facebook.com/10151255420886749/likes?limit=25&offset=25&__after_id=100003737463206"
   }
}

https://graph.facebook.com/10151255420886749

{
   "id": "10151255420886749",
   "from": {
      "category": "Politician",
      "name": "Barack Obama",
      "id": "6815841748"
   },
   "name": "Four more years.",
   "picture": "http://photos-a.ak.fbcdn.net/hphotos-ak-ash4/409202_10151255420886749_2117448131_s.jpg",
   "source": "http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s720x720/409202_10151255420886749_2117448131_n.jpg",
   "height": 478,
   "width": 720,
   "images": [
      {
         "height": 1359,
         "width": 2048,
         "source": "http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s2048x2048/409202_10151255420886749_2117448131_n.jpg"
      },
      {
         "height": 532,
         "width": 800,
         "source": "http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/409202_10151255420886749_2117448131_n.jpg"
      },
      {
         "height": 478,
         "width": 720,
         "source": "http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s720x720/409202_10151255420886749_2117448131_n.jpg"
      },
      {
         "height": 398,
         "width": 600,
         "source": "http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s600x600/409202_10151255420886749_2117448131_n.jpg"
      },
      {
         "height": 318,
         "width": 480,
         "source": "http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s480x480/409202_10151255420886749_2117448131_n.jpg"
      },
      {
         "height": 212,
         "width": 320,
         "source": "http://sphotos-a.ak.fbcdn.net/hphotos-ak-ash4/s320x320/409202_10151255420886749_2117448131_n.jpg"
      },
      {
         "height": 119,
         "width": 180,
         "source": "http://photos-a.ak.fbcdn.net/hphotos-ak-ash4/409202_10151255420886749_2117448131_a.jpg"
      },
      {
         "height": 86,
         "width": 130,
         "source": "http://photos-a.ak.fbcdn.net/hphotos-ak-ash4/409202_10151255420886749_2117448131_s.jpg"
      },
      {
         "height": 86,
         "width": 130,
         "source": "http://photos-a.ak.fbcdn.net/hphotos-ak-ash4/s75x225/409202_10151255420886749_2117448131_s.jpg"
      }
   ],
   "link": "http://www.facebook.com/photo.php?fbid=10151255420886749&set=a.53081056748.66806.6815841748&type=1",
   "icon": "http://static.ak.fbcdn.net/rsrc.php/v2/yz/r/StEh3RhPvjk.gif",
   "created_time": "2012-11-07T04:15:07+0000",
   "updated_time": "2012-11-07T04:15:07+0000",
   "comments": {
      "data": [
         {
            "id": "10151255420886749_12810477",
            "from": {
               "name": "David Carol",
               "id": "100003175318626"
            },
            "message": "BISHOP ZACHARY KAKOBE VERIFIED AIDS HEALING MIRACLES IN HIS MINISTRIES. THIS MINISTRY REGISTERED IN U.S.A IN 2010. WEBSITE: WWW.bishopzacharykakobe.org",
            "can_remove": false,
            "created_time": "2012-11-28T20:00:21+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12811019",
            "from": {
               "name": "Lievin Bangali",
               "id": "1812106678"
            },
            "message": "Barack Obama, Felicitation de votre reelection. Il est grand temps d'agir pour la situation de l'EST de la RD Congo. Merci et courage!",
            "can_remove": false,
            "created_time": "2012-11-28T20:40:28+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12811211",
            "from": {
               "name": "Pamela Aupindi",
               "id": "100004586432226"
            },
            "message": "President Obama is not only a charismatic leader but an obviously passionate man. One can feel the love for his wife through the pic! Amazing",
            "can_remove": false,
            "created_time": "2012-11-28T20:54:40+0000",
            "like_count": 1,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12811850",
            "from": {
               "name": "Ardavan Shafiie",
               "id": "1174217484"
            },
            "message": "graet picture",
            "can_remove": false,
            "created_time": "2012-11-28T21:35:26+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12812793",
            "from": {
               "name": "Samson Anifowose",
               "id": "658496517"
            },
            "message": "All the best!",
            "can_remove": false,
            "created_time": "2012-11-28T22:51:30+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12814187",
            "from": {
               "name": "Yago Costa",
               "id": "100000919886198"
            },
            "message": "isso ae negao !!!",
            "can_remove": false,
            "created_time": "2012-11-29T00:39:57+0000",
            "like_count": 1,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12814238",
            "from": {
               "name": "Sena Raharja",
               "id": "100004587874401"
            },
            "message": "wow",
            "can_remove": false,
            "created_time": "2012-11-29T00:43:08+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12814255",
            "from": {
               "name": "Getachew Biratu",
               "id": "100004104261949"
            },
            "message": "Better \u0040 home...!!!",
            "can_remove": false,
            "created_time": "2012-11-29T00:43:45+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12814350",
            "from": {
               "name": "Bennydictus Ari Setiabudi",
               "id": "714307966"
            },
            "message": "uhuk... lama2 terkikis image seno raharjo... XD",
            "can_remove": false,
            "created_time": "2012-11-29T00:50:10+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12814615",
            "from": {
               "name": "Sena Raharja",
               "id": "100004587874401"
            },
            "message": "mukanya mirip gua. Ini foto bikin rekor dunia.",
            "can_remove": false,
            "created_time": "2012-11-29T01:06:44+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12814662",
            "from": {
               "name": "Bennydictus Ari Setiabudi",
               "id": "714307966"
            },
            "message": "beda nasib dikit doang kali y... hehehe... :D",
            "can_remove": false,
            "created_time": "2012-11-29T01:09:59+0000",
            "like_count": 1,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12814794",
            "from": {
               "name": "Subhash Biradar",
               "id": "100003474405756"
            },
            "message": "    Its better...ha ha ha ha.",
            "can_remove": false,
            "created_time": "2012-11-29T01:20:35+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12815269",
            "from": {
               "name": "Barbara J. Beverly",
               "id": "1348022951"
            },
            "message": "I am still smiling and happy....such a wonderful day in America.",
            "can_remove": false,
            "created_time": "2012-11-29T01:51:15+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12815652",
            "from": {
               "name": "Phillip Mason",
               "id": "100001280178407"
            },
            "message": "Makes me want to throw up. The Muslim and his ..........",
            "can_remove": false,
            "created_time": "2012-11-29T02:17:19+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12815699",
            "from": {
               "name": "Jeremiah Bates",
               "id": "100000912015322"
            },
            "message": "The clown above me is far below me .",
            "can_remove": false,
            "created_time": "2012-11-29T02:21:04+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12815758",
            "from": {
               "name": "Jeremiah Bates",
               "id": "100000912015322"
            },
            "message": "Sad...Phillip Mason, they have self help tapes, education programs, support groups for uneducated fools such as yourself....",
            "can_remove": false,
            "created_time": "2012-11-29T02:26:12+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12816036",
            "from": {
               "name": "Romy Christie",
               "id": "100003856980181"
            },
            "message": "To Barbara J Beverly, I completely agree with you, what a Wonderful day for America, long live President Obama, may his next four years leave him a shining place in history! Great charisma and a great orator, I believe that he is doing his utmost with the heavy burden that was put upon his shoulders when he first began... From Romy, British National, Permanent resident in Tokyo Japan.November 29th2012 instant.",
            "can_remove": false,
            "created_time": "2012-11-29T02:45:35+0000",
            "like_count": 1,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12818055",
            "from": {
               "name": "\u0122in \u01feblsk\u00e5 K\u00e4n\u0115",
               "id": "100001520690200"
            },
            "message": "\u0641\u0649 \u0627\u064a\u0647 \u064a\u0627 \u0648\u0644\u0627\u062f \u0627\u0644.........",
            "can_remove": false,
            "created_time": "2012-11-29T06:37:20+0000",
            "like_count": 1,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12818064",
            "from": {
               "name": "Cm Amgad",
               "id": "100001979501265"
            },
            "message": "\u0627\u0646\u062a\u0627 \u064a\u0627 \u0639\u0645 \u0628\u0627\u0631\u0627\u0643 \u0627\u0648\u0628\u0627\u0645\u0627",
            "can_remove": false,
            "created_time": "2012-11-29T06:38:26+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12818067",
            "from": {
               "name": "Cm Amgad",
               "id": "100001979501265"
            },
            "message": "\u0644\u0645\u0627 \u0627\u0644\u0627\u0633\u062a\u0627\u0630 \u062c\u064a\u0646 \u064a\u062a\u0643\u0644\u0645 \u062a\u0631\u062f \u0639\u0644\u064a\u0629 \u064a\u0627 \u0643\u0633\u0645\u0643",
            "can_remove": false,
            "created_time": "2012-11-29T06:39:21+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12818275",
            "from": {
               "name": "Denise Mutty Henry",
               "id": "707184927"
            },
            "message": "who is the boss? michele of course",
            "can_remove": false,
            "created_time": "2012-11-29T07:21:36+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12818295",
            "from": {
               "name": "Steve Muguerza",
               "id": "100001926262266"
            },
            "message": "Dont worry honey I will do as you say and begin down america with the americas helping me they are so so weak we will just send them a check and keep them down like we keep the blacks down and in their place. Keep them poor and uneducated and teach them to rap.",
            "can_remove": false,
            "created_time": "2012-11-29T07:25:55+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12818637",
            "from": {
               "name": "David Torrens",
               "id": "699130216"
            },
            "message": "So USA votes for the right team after all.  And there was me thinking you might go back to a rather bushy nut.",
            "can_remove": false,
            "created_time": "2012-11-29T08:48:22+0000",
            "like_count": 1,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12818837",
            "from": {
               "category": "Fictional character",
               "name": "\u0645\u064f\u0640\u0633\u062a\u062d\u064a\u0640\u0640\u0640\u0640\u0644 \u0623\u0646\u0640\u0633\u0640\u0640\u0640\u0640\u0627\u0643\u064a\u0650 \u0644\u0623\u0646\u0646\u0651\u0640\u0640\u0640\u0640\u064a \u0639\u0627\u064a\u0640\u0640\u0640\u0640\u0634\u064c \u0639\u0644\u0640\u0640\u0640\u0640\u064a \u0630\u0643\u0640\u0640\u0640\u0631\u0627\u0643\u0640\u0640\u0640\u0640\u0640\u064a\u0650",
               "id": "101906399977956"
            },
            "message": "http://www.facebook.com/pages/\u0025D9\u002585\u0025D9\u00258F\u0025D8\u0025B3\u0025D8\u0025AA\u0025D8\u0025AD\u0025D9\u00258A\u0025D9\u002580\u0025D9\u002580\u0025D9\u002580\u0025D9\u002580\u0025D9\u002580\u0025D9\u002580\u0025D9\u002584-\u0025D8\u0025A7\u0025D9\u002586\u0025D8\u0025B3\u0025D9\u002580\u0025D9\u002580\u0025D9\u002580\u0025D9\u002580\u0025D9\u002580\u0025D8\u0025A7\u0025D9\u002583\u0025D9\u00258A-\u0025D9\u002584\u0025D8\u0025A3\u0025D9\u002586\u0025D9\u002586\u0025D9\u00258A-\u0025D8\u0025B9\u0025D8\u0025A7\u0025D9\u00258A\u0025D8\u0025B4-\u0025D8\u0025B9\u0025D9\u002584\u0025D9\u00258A-\u0025D8\u0025B0\u0025D9\u002583\u0025D8\u0025B1\u0025D8\u0025A7\u0025D9\u002583\u0025D9\u00258A/101906399977956?ref=hl",
            "can_remove": false,
            "created_time": "2012-11-29T09:36:54+0000",
            "like_count": 0,
            "user_likes": false
         },
         {
            "id": "10151255420886749_12819093",
            "from": {
               "name": "Mojisola Otu",
               "id": "100000238597273"
            },
            "message": "All the Best.\nMy family prays for yours.",
            "can_remove": false,
            "created_time": "2012-11-29T10:41:24+0000",
            "like_count": 1,
            "user_likes": false
         }
      ],
      "paging": {
         "next": "https://graph.facebook.com/10151255420886749/comments?limit=25&offset=25&__after_id=10151255420886749_12819093"
      }
   },
   "likes": {
      "data": [
         {
            "id": "100004002885259",
            "name": "Camy Doyna"
         },
         {
            "id": "100003495050210",
            "name": "Louzoco de Carvasal"
         },
         {
            "id": "536183064",
            "name": "Emily Brearley"
         },
         {
            "id": "100002742193990",
            "name": "Rosette Gracia Moukengue"
         },
         {
            "id": "100001107540696",
            "name": "Pac\u00f4me Chazelle"
         },
         {
            "id": "100001035425365",
            "name": "Niklas Pulli"
         },
         {
            "id": "100003292089993",
            "name": "Barbara Grimm"
         },
         {
            "id": "642830020",
            "name": "Elin Vinterhed"
         },
         {
            "id": "100000718890127",
            "name": "Katya Katyusha"
         },
         {
            "id": "1644725575",
            "name": "Lara Corti"
         },
         {
            "id": "100002024205882",
            "name": "Garibyan Anna"
         },
         {
            "id": "100002159247248",
            "name": "Marcos Fernando"
         },
         {
            "id": "1725354804",
            "name": "Kevin Burk"
         },
         {
            "id": "1524833123",
            "name": "Roberto TwoHands Bertuccelli"
         },
         {
            "id": "1056165559",
            "name": "Arman Hossain Anand"
         },
         {
            "id": "1052974324",
            "name": "Kathy Johng Shelton"
         },
         {
            "id": "100000254736003",
            "name": "Tina Mosely"
         },
         {
            "id": "595281527",
            "name": "Kim Fontaine-Skronski"
         },
         {
            "id": "100002935725139",
            "name": "Iulian Boxerul"
         },
         {
            "id": "100001450004383",
            "name": "Nora Lachgar"
         },
         {
            "id": "100001859484728",
            "name": "Joan Breen"
         },
         {
            "id": "1802479070",
            "name": "Jan Meyer"
         },
         {
            "id": "1815802454",
            "name": "Gregory Nobre"
         },
         {
            "id": "100002988798465",
            "name": "Aika JU"
         },
         {
            "id": "100003737463206",
            "name": "Ingrid Theiszov\u00e1-Bajusov\u00e1"
         }
      ],
      "paging": {
         "next": "https://graph.facebook.com/10151255420886749/likes?limit=25&offset=25&__after_id=100003737463206"
      }
   }
}

Doing something like adding a paging limit parameter with a ridiculously high value is way too slow... is there a way to get the count number straight up?

解决方案

You can retrieve this information via the photo FQL table:

select like_info from photo where object_id = 10151255420886749;

Returns:

{
  "data": [
    {
      "like_info": {
        "can_like": true, 
        "like_count": 4444816, 
        "user_likes": false
      }
    }
  ]
}

这篇关于Facebook GRAPH API照片如无分页计数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆