Here is a consolidated reference collection of official code snippets and syntax for popular Facebook social plugins that I frequently use when setting up WordPress websites.

Facebook Social Plugins

Facebook Like/Recommend Button

Facebook Comment

Note: Facebook’s social plugins generally consist of two parts. What is outlined above is the second part—the presentation embed code placed at specific locations on web pages, which is reusable. The first part involves individual application IDs and only requires loading a single JavaScript SDK once per site, so it is omitted here. If needed, please refer to Reference 1 on Facebook’s developer portal.

WordPress ShortCode

Displaying Google Maps in an article: Replace the official iframe embed code with [googlemaps https://www.google.com/maps/d/u/0/embed?mid=z-gBePi9AFJU.ksKcIQvWTn0k&w=964&h=500], making sure the end of the URL is formatted as &w=964&h=500.

To be updated.

Reference:

  1. Facebook Developer - Social Plugins.
✦ Independent Journalism · Reader Support ✦

Support Independent Perspectives & In-Depth Insights

Every thoughtful analysis and candid critique comes from our dedication to truth and quality. We choose not to follow sensational algorithms or clickbait headlines.

Sustaining independent research requires reader support. Make a one-time or monthly contribution, securely processed by Google.

Payments secured by Google · Manage or cancel anytime in your Google Account