【问题标题】:Facebook open graph image is not displayed on the first share, even though width and height are defined即使定义了宽度和高度,Facebook 开放图形图像也不会显示在第一个共享上
【发布时间】:2017-01-24 15:18:01
【问题描述】:

在过去几周内,显示共享页面的窗口(在提交共享之前)在第一次共享页面时未显示指定的 og:image。图片显示在共享帖子本身和后续共享请求中。

我们通过 FB 调试器运行我们的页面并收到以下消息

提供的“og:image”属性尚不可用,因为新 图像是异步处理的。确保共享新 URL 包含图像,使用“og:image:width”指定尺寸和 'og:图像:高度'标签。了解更多

问题是我们确实定义了 og:image:width 和 og:image:height 标签,FB 调试器甚至将它们显示在显示此消息的同一页面上...参见下面的附图。

知道是什么原因造成的吗?

【问题讨论】:

  • 很多人都有这个问题,包括我自己。我现在怀疑 fb 已经破坏了他们已经脆弱的 og 抓取系统。
  • 这是官方 facebook 跟踪器上的一个错误,看起来与问题中描述的错误完全相同:developers.facebook.com/bugs/184653232016624即使我几个月没有进行任何更改,我的分享页面也崩溃了。跨度>
  • 10x 用于关于 fb 错误的通知!

标签: facebook facebook-graph-api facebook-opengraph


【解决方案1】:

我认为这是上面提到的 Alexey 的 Facebook 错误。 https://developers.facebook.com/bugs/184653232016624/

但是,一种解决方法似乎是通过他们的 api 启动预取。

curl -X POST \
-F "id=http://your.url/here" \
-F "scrape=true" \
"https://graph.facebook.com"

【讨论】:

    猜你喜欢
    • 2015-11-09
    • 1970-01-01
    • 2019-10-10
    • 2023-03-22
    • 2011-04-09
    • 2012-10-27
    • 1970-01-01
    • 1970-01-01
    • 2014-04-04
    相关资源
    最近更新 更多