我试图找出Facebook共享协议如何获取图像。
示例文章:http://www.startribune.com/sleepy-eye-quads-celebrate-65th-birthday/302364361/
截至目前(2015年5月8日下午1点,CDT),将该网址插入https://developers.facebook.com/tools/debug/og/object/,会发出以下警告:og:image was not defined, could not be downloaded or was not big enough. Please define a chosen image using the og:image metatag, and use an image that's at least 200x200px and is accessible from Facebook. Image 'http://stmedia.stimg.co/obed021814.JPG?w=600&h=600' will be used instead.
然而,在“基于原始标记”的页面上,我们构建了以下“打开图形”属性'页面的一部分,它清楚地显示页面上的og:image标签中的正确图像。
为什么Open Graph会认为og:图像没有定义,或者当它可以找到它的页面更远的地方时无法访问图像?
标题中的元标记如下:
<link rel="canonical" href="http://www.startribune.com/sleepy-eye-quads-celebrate-65th-birthday/302364361/" />
<meta property="og:url" content="http://www.startribune.com/sleepy-eye-quads-celebrate-65th-birthday/302364361/" />
<meta property="og:title" content="Sleepy Eye quads celebrate 65th birthday" />
<meta property="og:site_name" content="Star Tribune" />
<meta name="news_keywords" content="" />
<meta name="description" content="The Sleepy Eye quads have returned to their childhood home in southern Minnesota to celebrate their 65th birthday." />
<meta property="og:description" content="The Sleepy Eye quads have returned to their childhood home in southern Minnesota to celebrate their 65th birthday."/>
<meta property="og:image" content="http://stmedia.startribune.com/images/1430701562_10026501+Quads+Birthday.JPG" />
</head>
答案 0 :(得分:0)
如@CBroe所述,运行Facebook Debugger中与页面相关的所有链接总是好的。
至于具体图片问题,我还建议您添加og:image:width
和og:image:height
元标记,以帮助抓取工具按照此doc抓取您的图片。
如果您有其他页面遇到同样的问题,我会在尝试在调试器中运行图像网址之前提供上述标记,看看是否有帮助。