如何在 Facebook 中嵌入我自己的视频播放器?

发布于 2024-10-09 22:23:56 字数 100 浏览 2 评论 0原文

是否可以在 Facebook 中嵌入我自己的视频播放器,以便我可以像所有 YouTube 视频一样直接在时间轴中查看视频?

是否需要在 中包含任何元标记?我网站的部分?

Is it possible to embed my own video player in Facebook, so I can see the video directly in the timeline, like all the YouTube videos?

Are there any metatags I need to include in the <head> section of my site?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

疑心病 2024-10-16 22:23:56

为了补充其他答案,Facebook 最近发布的一篇开发者帖子(我目前似乎找不到)推断不再需要白名单。不管怎样我还是这么做了。大约需要一周时间。

您需要使用开放图谱协议。有关嵌入视频的信息位于此页面底部:http://developers.facebook.com/docs/ opengraph/

这是我们通过实验发现的(将来肯定会改变):

  • 播放器必须是flash播放器。
  • 它必须是 https 链接。
  • 您可以添加可选的 flashvars 作为参数。

我们网站上的 og:video 标签示例:

<meta property="og:video" content="https://indieflix.com/media/swf/player.swf?bufferlength=3&lightcolor=FFFFFF&autostart=true&file=http%3A%2F%2Findieflix.com%2Fstreamer%2Fhdtrailer%2F32310_320x180.mp4&provider=http&frontcolor=CCCCCC&image=http%3A%2F%2Fcdn.indieflix.com%2Ffilms%2Fimages%2Flarge%2F32310.jpg&backcolor=333333" />

To add to the other answers, a recent developer post from Facebook (which I can't seem to find at the moment) inferred that whitelisting was no longer necessary. I did it anyway. Takes about a week.

You need to use the Open Graph protocol. Info on embedding video is at the bottom of this page: http://developers.facebook.com/docs/opengraph/

This is what we found through experimentation (which will certainly change in the future):

  • The player must be a flash player.
  • It must be an https link.
  • You can add optional flashvars as parameters.

An example og:video tag from our website:

<meta property="og:video" content="https://indieflix.com/media/swf/player.swf?bufferlength=3&lightcolor=FFFFFF&autostart=true&file=http%3A%2F%2Findieflix.com%2Fstreamer%2Fhdtrailer%2F32310_320x180.mp4&provider=http&frontcolor=CCCCCC&image=http%3A%2F%2Fcdn.indieflix.com%2Ffilms%2Fimages%2Flarge%2F32310.jpg&backcolor=333333" />
您的好友蓝忘机已上羡 2024-10-16 22:23:56

您必须首先通过提交视频嵌入白名单请求。

一旦获得批准(当我回顾我的请求的电子邮件时,我花了 4 个小时),您的播放器将能够像 YouTube 视频一样显示。然后,您可以使用 fire 在他的回复中提到的 Facebook Share 帮助指南。另外,另一个有用的东西是 URL Linter,它告诉您 Facebook 如何解释 Facebook 上的元数据你的页面。

You must first get your Flash player approved by submitting a video embed whitelist request.

Once this is approved, which took 4 hours for me when I look back on emails from my request, your player will be able to be shown just as YouTube videos are. You can then use the Facebook Share help guide which fire mentioned in his reply. Also, another helpful thing is the URL Linter which tells you how Facebook is interpreting the metadata on your pages.

半世蒼涼 2024-10-16 22:23:56

是的,有一个元标记,但我不确定您自己的 Flash 视频播放器是否会直接嵌入。请查看共享 Rich Media 部分。

Yes, there is a meta tag though I am not sure if your own Flash video player will get directly embedded. Take a look at the Sharing Rich Media section.

枕花眠 2024-10-16 22:23:56

不错的视频嵌入功能就像一个魅力,刚刚看到 YouTube 嵌入方式最近发生了变化。
预览它是一个带有播放按钮的小缩略图,即使被标记为最喜欢的故事。
现在,他们将视频嵌入为特色故事(明星)完整时间轴封面大小的缩略图,并带有播放按钮。这对于 Facebook 中嵌入的任何视频或 Flash 来说都非常有趣。

Nice Video embed works like a charm just saw a recent change how youtube embed.
Previews it was a smals thumbnail with a play button , even when marked as favorite story.
Now they embed video as featured story (the star) full Timeline cover sized Thumbnail with the play button .that is very interesting for any video or flash embed in facebook.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文