2013-12-11 67 views
1

在博客博客風格的博客上,有一天我可能在博客文章中有圖像,第二天有一個YouTube視頻,是否有可能在鏈接將博客文章發佈到Facebook,讓facebook以與在博客文章中找到圖片相同的方式查找併發布視頻?博客文章嵌入式YouTube視頻,鏈接和可在Facebook上播放

我見過其他人談論的「元標記」:

<meta name="og:type" content="video"> // This is important so that OP will recognize your site as video streaming site like YouTube & Vimeo 
    <meta property="og:video:type" content="application/x-shockwave-flash"> // Don't Change this 
    <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="mySWFVideoPlayer.swf?url=Video_Soure"> // You will need to echo/print the Video Source (I.E. *.mp4) with a help of PHP or whatever your server uses 

但meta標籤僅在該博客/網頁的使用,所以這意味着我只能夠設置1視頻爲整個博客,但我想使用嵌入在每個帖子(如果有嵌入視頻)的視頻

回答

0

對於嵌入YouTube視頻試試這個。這可能會以某種方式幫助你。 Meta標籤以這種方式非常有用。

<meta name='og:title' content='Big Buck Bunny'/> 
<meta name='og:type' content='movie' /> 
<meta name='og:url' content='http://testsite.com/testfile.html' /> //Your html meta tag file path 
<meta name='og:image' content='http://testsite.com/image.jpg' /> //Your image path 
<meta name='og:site_name' content='TestSITE'> 
<meta name='og:description' content='Big Buck Bunny is a short animated film by the Blender Institute, part of the Blender Foundation.'/> 
<meta property='og:video' content='http://testsite.com/jwplayer/player.swf?file=video.mp4' /> //Your video path with player 
<meta property='og:video:height' content='640'> 
<meta property='og:video:width' content='385'> 
<meta property='og:video:type' content='application/x-shockwave-flash' /> 
<meta property='og:video' content='http://testsite.com/video.mp4' /> //Your Video 
<meta property='og:video:type' content='video/mp4' /> //Your Video Type for Mobile 
<meta property='og:video:type' content='text/html' /> //Video type for other 
+0

元標籤的工作,但只爲全球網頁,特別是博客,我只知道如何更新根網站的標題。因此,如果我使用此代碼,則每次鏈接新博客帖子時都會引用同一視頻(而不是每個博文中的新視頻),並且Facebook拒絕不在中的元標記 – user3092659

相關問題