首页 > 解决方案 > 为什么 Open Graph 检查器无法检测 Open Graph 数据?

问题描述

我的页面在添加 SSL 证书 ( Let's Encrypt ) 后,在共享链接时无法通过 Facebook 或 Twitter 获取预览。我遵循开放图协议并包含以下开放图标签:

<meta property="og:type" content="article" />
<meta property="og:title" content="Corner Timer: gently make you feel guilty on time-wasting apps" />
<meta property="og:url" content="https://lyminhnhat.com/resources/productivity/corner-timer-gently-make-you-feel-guilty-on-time-wasting-apps/" />
<meta property="og:description" content="Make you feel guilty for your unproductive curiosity" />
<meta name="twitter:site" content="@ooker777" />
<meta name="twitter:text:title" content="Corner Timer: gently make you feel guilty on time-wasting apps" />
<meta name="twitter:image" content="https://lyminhnhat.com/wp-content/uploads/2019/04/Screenshot_2019-04-11-11-31-39.png?w=640" />
<meta name="twitter:card" content="summary_large_image" />

但是,我使用的所有 3 个 Open Graph 检查器——OpenGraphCheck.comAbhinay Rathore 的 Open Graph TesterFacebook 的 Object Debugger——都说没有 Open Graph 实现。不过有一个例外:Iframely 的嵌入代码

由于所有三个检查器都有这个问题,可能这不仅仅是 Facebook 的问题,正如FB OpenGraph og:image not pull images (possibly https?)中所建议的那样。然而,即使我尝试仅使用 html 链接,剥离结束空白,使用<html prefix="og: http://ogp.me/ns#">.

此人建议这可能是服务器问题。你知道为什么会这样吗?


相关:使用 SSL 的新网站是否已经避免了 Open Graph 问题?

标签: urlssl-certificatemetafacebook-opengraph

解决方案


就我而言,爬虫似乎只是有一个错误。我在这个问题上有自己的规范答案,希望对某人有所帮助:FB OpenGraph og:image not pull images (possibly https?)


推荐阅读