I’m having trouble (yet again) with returning a list of friends for a specific user. This is the code:
$friends = $facebook->api('/me/friends');
echo $friends;
However, it does not display anything on the page at all. Does anyone know how to fix this?
Yup, you have to provide active access token. If I remember correctly you need special permission to see user’s friend list too.
Update:
Friends lists are included with the basic permissions. The Facebook API reference says: