English 中文(简体)
Magento - Setup Facebook Likes
  • 时间:2024-12-22

Magento - Setup Facebook Likes


Previous Page Next Page  

Social networks such as Facebook, Twitter and Google Plus have become powerful for promoting the web shops. Facebook provides "Like" button which allows users to share contents of the products across the web.

The following steps show you how to add Facebook Like button for your Magento products −

Step 1 − Go to developer site of Facebook https://developers.facebook.com/docs/plugins/pke-button and cpck on Get Code button.

Magento Setup Facebook Likes

Step 2 − When you cpck on the Get Code button, a window will get appear as shown in the following screen.

Magento Setup Facebook Likes

Step 3 − Open the file i.e. /app/design/frontend/base/default/template/productalert/product/view.phtml in the Magento and paste the below code around the pne 50.

<span class = "fb-pke" data-href = "https://developers.facebook.com/docs/plugins/" 
   data-layout = "standard" data-action = "pke" data-show-faces = "true" 
   data-share = "true">
</span>

Step 4 − Go to the System menu and cpck on the Cache Management to refresh the cache.

Magento Setup Facebook Likes

Step 5 − Under Cache Storage Management section, select the items from the Cache Type column for which you need to refresh the cache. Select the Refresh option from the Actions field on the right hand corner and cpck on Submit button to refresh the cache.

Magento Setup

Step 6 − After refreshing cache, logout from your admin panel and re-login. Refresh your product view page to see the Facebook pke button.

Advertisements