问题描述:

I've pasted the following code to my site in order to implement a facebook like button:

<div class="fb-like" data-href="http://example.com/blog/article/28" data-send="false" data-width="450" data-layout="button_count" data-show-faces="false"></div>

And I have the following meta tags:

<meta property="og:type" content="website" />

<meta property="fb:app_id" content="123412341234123" />

<meta property="og:url" content="http://example.com/blog/article/28" />

<meta property="og:image" content="http://example.com/images/branding/logo7.png" />

<meta property="og:title" content="Testing Title - Sitename" />

<meta property="og:description" content="some description" />

I've tried the Facebook Object Debugger and it show that all the data is scraped correctly.

The image in the og:image tag is 16.78KB 450x450px PNG Image and it seems to meet the only requirement that I've found ( 200x200px minimum width and height).

When I click on the like button it's working but as an associated image with the like appears "Pin It" button that I've also implemented.

My question is what am I missing, is there a way to display the proper image with each like ?

网友答案:

All the og tags need to match correctly. precisely accurate url tags need to scraped by facebook.

For instance

example dot com

is not the same as

www dot example dot com

is not the same as

www dot example dot com/index dot php

I am not sure how precise the match needs to be but it does matter.

Also the Canonical URL seems to need to match the Fetched URL and they both seem to need to match the url navigated to. Created alternative relative links to the same scraped url is not good.

相关阅读:
Top