Reputation: 30885
I had this API that gives me all the images in my galleries. Now, when I'm using it outside of the Facebook applications, and just as web application, I getting an empty array.
$user = $facebook->getUser();
echo "$user<br>"; // gives me the uid
$user_albums_photos = $facebook->api(array(
'method' => 'fql.query',
'query' => 'SELECT src,src_big FROM photo WHERE aid IN (SELECT aid FROM album WHERE owner=me())'
));
print_r($user_albums_photos); // Gives me an empty array, when it's a web application.
$r_c = count($user_albums_photos);
echo "<br>$r_c<br>";
Upvotes: 0
Views: 206
Reputation: 31860
The query looks fine and I am able to run it no problem when I provide a good user access token. Lint your access token at https://developers.facebook.com/tools/lint and see if it has the appropriate permissions (https://developers.facebook.com/docs/reference/api/permissions/).
Upvotes: 1