zer*_*net 13 embed youtube video html5 facebook
我有一个拥有HTML5视频播放器的网站.
我想分享链接(例如:http://site.com/video/example-2在Facebook上),用户点击Facebook上的那个帖子的图像,然后开始在那里播放视频.
就像youtube视频和vimeo视频一样.
我怎样才能做到这一点?
谢谢
Ada*_*zad 19
我有一个拥有HTML5视频播放器的网站.
你想找到一个可以流式传输视频的好SWF(*.SWF)视频播放器url={video_Hot_link}(将URL参数传递给SWF播放器)
现在,当您的SWF播放器准备好播放一些视频后,将Facebook Open Graph添加
到您的<head>标签中,如下所示:
<meta property="og:type" content="video"> <!-- site/page type more information http://ogp.me/ -->
<meta property="og:video:type" content="application/x-shockwave-flash"> <!-- you need this because your player is a SWF player -->
<meta property="og:video:width" content="Width in Pixels"> <!-- player width -->
<meta property="og:video:height" content="Height in Pixels"> <!-- player height -->
<meta property="og:video" content="http://example.com/{path_to}/{swf_player}.swf?url={video_soure}"> <!-- You will need to echo/print the video source (*.mp4) with server-side code -->
<meta property="og:video:secure_url" content="https://example.com/{path_to}/{swf_player}.swf?url={video_soure}"> <!-- required for users whom use SSL (actually Facebook forces everyone to use SSL so you're required to use og:video:secure_url) so get a one -->
Run Code Online (Sandbox Code Playgroud)
此外,您需要将以下前缀添加到<html>likeso
<html prefix="og: http://ogp.me/ns#">
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
19080 次 |
| 最近记录: |