Reputation: 985
Through a lack of good documentation of the Facebook Graph I need your help.
I use this piece of php code to get posts form a Facebook page:
file_get_contents_curl("https://graph.facebook.com/v2.6/$pageFBID/feed?fields=full_picture,message,story,created_time,shares,likes.limit(1).summary(true),comments.limit(1).summary(true)&access_token=".$token);
This call works fine but I want to get all the images, instead of only one. Does someone know how?
Upvotes: 1
Views: 264
Reputation: 985
I finnaly found the soluction. You have to add the 'parameter' attachments to the url to get all the images and other media attached to the post, in a large size.
file_get_contents_curl("https://graph.facebook.com/v2.6/$pageFBID/feed?fields=full_picture,attachments,message,story,created_time,shares,likes.limit(1).summary(true),comments.limit(1).summary(true)&access_token=".$token);
Upvotes: 1