如何使用Koala宝石获取Facebook用户的图片? [英] How to get the picture of Facebook User using Koala gem?

查看:125
本文介绍了如何使用Koala宝石获取Facebook用户的图片?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用
获取Facebook用户的朋友的照片,而使用以下代码返回nil,而不是
的图片url ...

I am trying to fetch the picture of a Facebook user's friends using their facebook ids, but using the following code returns nil instead of the picture url...

我使用的代码如下:

picture_url = @user.get_picture("1000000111")

其中@user是使用Facebook
身份验证的Graph API对象...

where @user is the Graph API Object made using Facebook authentication...

此代码中缺少什么?提前致谢。

What is missing in this code?? Thanks in advance.

推荐答案

我不知道考拉,但如果您要求用户的标识符(以 graph.facebook.com/odedharth/picture )你可以得到它。

I don't know about Koala, but if you ask for the user's identifier ( in the form of graph.facebook.com/odedharth/picture ) you can get it.

这篇关于如何使用Koala宝石获取Facebook用户的图片?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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