how to get facebook user album's id using php facebbok API
I am trying to get facebook user albums id and I am using this code
$f开发者_Go百科riendsalbum = $facebook->api("/userID/albums/");
where userID is the user facebook id but it returm me empty array.
Well i used this code in app
$albums = $facebook->api('/me/albums?fields=name,link');
Here is the sample app.
Ensure that you have the friends_photos
permission set in your application and the following call should work
$friendsalbum = $facebook->api("/userID/albums/");
If it returns empty after this it means that the user's privacy setting is blocking you from accessing this data.
精彩评论