问题
I have a website with many video pages. There is only one video on each page. When i share a link of one of these pages on facebook, it is not considered as a video, but only a standard article.
Thumbnail, Title and Decription are well displayed. But instead of displaying the thumbnail, i would like Facebook to display the video.
I'm using videoJS as video player.
Here is my html header:
<meta property="og:title" content="Page Title" />
<meta property="og:description" content="Page Description" />
<meta property="fb:admins" content="ADMIN-ID" />
<meta property="fb:app_id" content="APP-ID" />
<meta property="og:image" content="/path/to/the/thumbnail.jpg" />
<meta property="og:type" content="video" />
<meta property="og:url" content="www.domain.com/video.html" />
<meta property="og:video" content="www.domain.com/video.mp4" />
<meta property="og:video:type" content="video/mp4" />
And my video :
<video id="video_1" class="video-js vjs-default-skin shadow" controls preload="auto" width="686" height="386" poster="path/to/the/poster.png">
<source src="path/to/the/video.mp4" type='video/mp4' />
</video>
Here are the Facebook Debug Tool informations :
{
"url": "http:\/\/www.domaine.com\/video.mp4",
"type": "video\/mp4",
"width": 686,
"height": 386
}
and
status :
Video embedding on Facebook enabled
Thanks for your help and your comprehension, i'am a newbe in Facebook API.
回答1:
Do you have HTTPS URLs for your video files in the OG meta tags as well?
You will need HTTPS sources as well, since most Facebook users surf over HTTPS already (and Facebook is in the process of getting the rest of them there).
来源:https://stackoverflow.com/questions/18784356/facebook-doesnt-detect-video-while-sharing-my-own-page