开发者

Facebook SEO with image not loading [duplicate]

This question already has answers here: Closed 11 years ago.

Possible Duplicate:

How does Facebook Sharer select Images?

I've got an app recently put online. On my Facebook wall, when I type in the URL to my app. Facebook displays available thumbnails. At the moment it's displaying GoDaddy's thumbnails. I'm guessing its because Facebook is caching the images.

So I read somewhere about putting image_src on the <head> element. In Rails 3.1 should it be:

<link rel="image_src" href="http://www.site_name.com/assets/logo.png" />

Or:

<link rel="image_src" href="/assets/logo.png" />

And is using <link rel="image_src" the right meta tag to show the right thumbnail on Facebook? If so, do I have to wait a few hours until the thumbnail displays on Facebook?

EDIT

I have:

  <meta property="og:title" content="<%= yield(:title).present? ? yield(:title) : 'Foobar' %>" />
  <meta property="og:type" content="website" />
  <meta property="og:url" content="<%= request.url %>" />
  <meta property="og:image" content="http://www.foobar.com/assets/logo.png" />
  <meta property="og:site_name" content="Foobar" />

The Facebook debug page shows an actual image f开发者_运维技巧or og:image. But when I type the site's url on a wall, the thumbnail still doesn't appear


The best way to supply metadata to Facebook is using Open Graph tags.

The main documentation is at https://developers.facebook.com/docs/opengraph/

If you just want to get something set up quickly, use the form at 'Step 2' on the Like Button documentation which will produce a set of meta tags to put in to the <head></head> part of your page

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜