【发布时间】:2014-08-09 10:10:29
【问题描述】:
我正在做一个项目,该项目需要显示我的 Facebook 帐户的好友列表。当我分配我/朋友时,它会告诉我我帐户中的朋友数量,例如,{
“朋友”:{ “数据”: [ ], “概括”: { “总数”:122 } }, "id": "290538796816510" }
我没有在“数据”中得到任何名称。而另一方面,当我使用“我/朋友列表”时,它只会给我“亲密朋友”、“家人”等列表的名称。 谁能告诉我如何得到我朋友的名字。
【问题讨论】:
-
我也检查过.. 对我不起作用
-
请输入您的代码,以便我们提供帮助
-
我没有使用 fb sdk。我正在使用它的 json
-
SBJSON *jsonparser = [[SBJSON alloc]init]; FbGraphResponse *fb_graph_response = [fbGraph doGraphGet:@"me/friends" withGetVars:nil]; NSString *resultString = [NSString stringWithString:fb_graph_response.htmlResponse]; NSDictionary *firstDictionary = [jsonparser objectWithString:resultString]; NSArray *firstArray = [firstDictonary objectForKey:@"data"];
标签: ios json facebook-graph-api sbjson