Recently, we had a client who wanted the latest posts from their Facebook Page to appear automatically on their website.

PrestaShop doesn't have a built-in way to pull in social media content, so store owners are left updating their content in two places — once on Facebook, and again manually on the site.

For example, to keep a website's homepage in sync with a Facebook Page, you can do this:
Open Facebook, copy the text and image from your latest post, switch to your PrestaShop back office, create or edit a content block, paste the text, upload the image, and publish it.
Repeat this process every time you post something new — and update it again later if the post changes or gets deleted.

What does this module do

It pulls the latest posts from a Facebook Page via the Graph API and stores them in the store's database, then displays them as a post block on the PrestaShop website — you can choose which hook it appears on (homepage, footer, left/right column, etc.).

<h2>What does this module do</h2>

Why it was built

So that stores can automatically show their latest social feed on the website, instead of updating content in two places, or relying on an external embedded widget that loads slowly and can't be styled to match the site.

What problem it solves

  • The "cross-posting" duplication problem — the store owner posts once on Facebook and it appears on the website automatically.
  • The problem of Facebook CDN image links expiring — the module downloads the images and stores them on its own server (local cache).

How it works

  1. The admin sets the Facebook App ID/Secret and connects the Page through the configuration page.
  2. A front controller accepts requests with a secret token, allowing new posts to be synced automatically as a cron job, with no need to log into the back office.
  3. During sync, the system calls FacebookFetcher through Graph API v22.0 and saves the posts into a database table.
  4. There's an auto-renew system for the access token before it expires (it checks if fewer than 15 days remain).

Features

  • Choose which hook to display on yourself (Home, Footer, Left/Right column, Top, Bottom)
  • Set the number of posts to display (limit)
  • Set your own block title
  • Download post images to local storage (to prevent expired links)
  • Sync via a cron endpoint protected by a token, plus a Force Sync button in the back office
  • Automatic access token checking/renewal, with the latest error logged for the admin to see
<h2>Features</h2>

Other projects


Loading...