Facebook 是否维护一个域白名单,其内容在共享到时间线时显示不同?
在我的所有测试中,Facebook 似乎对待 Youtube & Vimeo 的视频嵌入方式与我们的不同。具体来说,当视频链接/嵌入共享到时间轴并设置为全角 2 列显示时,通过 og:image 指定的图像仍显示为缩小的缩略图(如它在 1 列显示模式下执行),并且 og:description 占据右侧的其余空间。
这与 Youtube 和 YouTube 形成鲜明对比。 Vimeo 嵌入共享,而是显示上面的 og:description(全角)和下面放大的 og:image,也是全角。
我尝试尽可能多地复制他们的开放图标签,包括类似的图像和视频尺寸、排序等,但在每种情况下,它似乎都不会以完全相同的方式对待我们的嵌入。我在每次测试后使用 FB URL linter 来中断缓存,并确保它正确提取我的 OG 标签。
观察:
- 当指定视频尺寸时,FB 会根据需要尝试缩小视频嵌入以适应较小的可用空间(时间轴 1 列显示)。
- 当未指定视频尺寸时,FB 会尝试将视频嵌入放大或缩小以适应完整的可用空间(1 列时间轴和更宽的 2 列时间轴) )。
- 列出多个不同大小的 og:images(每个都指定了自己的 og:image:width 和 height)似乎对根据上下文进行不同的显示没有任何影响; FB 总是抓取指定的第一个,并根据缩略图、新闻滚动条、时间线 1 和 2 列等的需要将其放大/缩小。
- 将 og:type 指定为“文章”(如 Vimeo 所做的那样)不会似乎对嵌入显示有任何影响。它的显示方式与正确指定为“video”或“video.movie”一样。
- 通过 og:image:width 和 height 指定图像尺寸似乎没有任何明显的效果(与不指定它们相比)。
有人有任何见解吗?随着最近时间线的引入,FB 对视频共享的开放图谱标签的实现似乎发生了很大的变化,但他们的文档没有反映这些变化,也没有反映它们如何最好地在时间线中显示。
In all of my testing it seems that Facebook treats Youtube & Vimeo's video embeds differently than our own. Specifically, when a video link/embed is shared to the Timeline and set to the full-width 2-column display, the image specified via og:image is still shown as a scaled-down thumbnail (as it does in the 1-column display mode), and the og:description occupies the rest of the space to the right.
This is in direct contrast to Youtube & Vimeo embed shares, which instead display the og:description above (full-width), and the scaled-up og:image below, also full-width.
I've tried to replicate as much as their Open Graph tags as possible, including similar image and video dimensions, ordering, etc, but in every instance it never seems to treat our embeds quite the same. I used the FB URL linter to break cache after each test, and to make sure it's pulling my OG tags properly.
Observations:
- When the video dimensions are specified, FB tries to scale the video embed down as necessary to fit a smaller available space (Timeline 1-column display).
- When the video dimensions are not specified, FB tries to scale the video embed up or down to fit the full available space (both 1-column Timeline and wider 2-column Timeline).
- Listing multiple og:images of varying sizes (each with their own og:image:width and height specified) does not seem to have any effect on displaying differently based on context; FB always grabs the first one specified, and scales it up/down as needed for thumbnails, news ticker, timeline 1- and 2-column, etc.
- Specifying the og:type as 'article' -- as Vimeo does -- does not seem to have any effect on the embed display. It displays it the same as if it was rightfully specified as 'video' or 'video.movie'.
- Specifying image dimensions via og:image:width and height do not seem to have any observable effect (compared to not specifying them).
Anyone have any insights? It seems FB's implementation of Open Graph tags for video shares have changed quite a bit with the recent introduction of Timeline, but their documentation does not reflect the changes, nor how they are best used for display in the Timeline.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论