如何让用户在Facebook的SDK 3.0的Andr​​oid Facebook的个人资料图片 [英] How to get facebook profile picture of user in facebook SDK 3.0 Android

查看:170
本文介绍了如何让用户在Facebook的SDK 3.0的Andr​​oid Facebook的个人资料图片的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Facebook的SDK 3.0我必须得到用户登录的个人资料图片。 这里是code我用:

i am using facebook SDK 3.0 i have to get profile picture of user login. Here is the code I use:

URL image_value = new URL("http://graph.facebook.com/"+id+"/picture" );
profPict=BitmapFactory.decodeStream(image_value.openConnection().getInputStream());

不过,我没有得到期望的结果。

But I don't get the desired result.

推荐答案

您应该改变你的code以下内容:

You should change your code following:

URL image_value = new URL("http://graph.facebook.com/"+id+"/picture" );

可能GET参数的URL可以在这里找到: <一href="https://developers.facebook.com/docs/graph-api/reference/user/picture/">https://developers.facebook.com/docs/graph-api/reference/user/picture/

Possible GET parameters for the URL can be found here: https://developers.facebook.com/docs/graph-api/reference/user/picture/

这篇关于如何让用户在Facebook的SDK 3.0的Andr​​oid Facebook的个人资料图片的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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