我正在尝试使用 og 标签在 Facebook 上共享音频内容,以便音频只能在 Facebook 窗口中播放。
这是我编写的代码:
<html>
<head>
<meta property="og:url" content="https://www.songdew.com/test_manish.html"/>
<meta property="og:image" content="https://s3-ap-southeast-1.amazonaws.com/sgmedia/13122/photos/t_ce0284c1ad98c8e79c3f3af7b8c297.jpg"/>
<meta property="fb:app_id" content="335931163095578"/>
<meta property="og:title" content="3. undead redemption" />
<link rel="canonical" href="https://www.songdew.com/test_manish.html"/>
<meta property="og:audio" content="https://s3-ap-southeast-1.amazonaws.com/sgmedia/18037/tracks/f7a43fcd2f8a15a0a1322bf3ac2429.mp3">
<!--<meta property="og:audio:title" content="manish23">
<meta property="og:audio:artist" content="Mkumar">
<meta property="og:audio:album" content="itsnew"> -->
<meta property="og:audio:type" content="application/mp3">
</head>
<title>This is test</title>
<style type="text/css">
#share-buttons img {
width: 35px;
padding: 5px;
border: 0;
box-shadow: 0;
display: inline;
}
</style>
<body>Thiis is a test Page
</body>
</html>
但是,音频不会在那里播放。我不明白这段代码有什么问题。如有任何帮助,我们将不胜感激!
最佳答案
您无法以某种方式共享音轨,以便它们立即内嵌播放。
如https://developers.facebook.com/docs/opengraph/music页面顶部明确指出,目前仅向少数列入白名单的 Facebook 合作伙伴开放。
一种可能的替代方案是将其嵌入为视频(Flash 和/或 mp4)。无论您制作的视频只是播放音频,并且视觉内容只是黑色或其他什么,还是使用视频来传输有关音轨的附加信息(例如谁是艺术家,也许是封面艺术作品,...),取决于你。
关于html - 使用开放图在 Facebook 上共享音频,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36521048/