This code can fetch the most recent posts on a multiple fan page, or community group, embedding them on your site.
For each post retrieved from Facebook, the also gets attached photos, link, along with the like, comment, and share counters.
Retrieved photos can be viewed at their natural size using a local modal window, and a link is also provided to view the original posts on Facebook.
To use, a Facebook Access Token is needed, but the process is quite simple and won't stop anyone with technical skills in getting it done.
This code is only 1 file and simple configuration:
$id_fb = '35688476100'; // groups id or pages id $base_url = 'http://domain-name.com/facebook/'; $access_token = '56721317246393|34Iz651tuyYta_278fR342vJHV1jI';
1. Bootstrap
2. jQuery
3. Fontawesome
4. Fancybox