需要从用户ID找到Facebook用户名 [英] Need to find Facebook username from user id
本文介绍了需要从用户ID找到Facebook用户名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
尝试:
$ userid ='100004471603852';
$ appid = **********;
$ url =https://graph.facebook.com/{$userid}?access_token={$appid};
$ result = file_get_contents($ url);
print_r($ result);
这将返回Name和User ID。我需要用户名(登录ID)。你可以帮助我如何做到这一点。
解决方案
我/用户名不再可用。资料来源: https://developers.facebook.com/docs/apps/changelog#v2_0
您不应该使用用户名,只需使用App Scoped User ID来识别用户。
I need to find Facebook username from userid.
Tried:
$userid = '100004471603852'; $appid = **********; $url = "https://graph.facebook.com/{$userid}?access_token={$appid}"; $result = file_get_contents($url); print_r($result);
This returns Name and User ID. I need username (login id). Could you please assist me how to do that.
解决方案me/username is no longer available.
Source: https://developers.facebook.com/docs/apps/changelog#v2_0
You are not supposed to use the username anymore, just use the App Scoped User ID to identify users.
这篇关于需要从用户ID找到Facebook用户名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文