在您的Facebook组中共享网页帖子的最佳方法是什么?
让我们以此为我的网站我的mywebsite.com/news.php
每条新闻都有其独特之处id
。
我的一篇网志文章的连结是 mywebsite.com/news.php?id=57
那么,当我要共享此链接时,如何制作自定义标题和图像mywebsite.com/news.php?id=57
?
我尝试使用facebook Graph API,但对我没有用。
当我粘贴我的Web帖子的链接(例如:)时,如何实现mywebsite.com/news.php?id=57
它基于基于帖子定义的Web帖子中的变量创建自定义图像和标题以进行共享id
,我的页面上的每个帖子(每个ID)都有其自定义图像和标题拥有
$title, $image, $description, $url
它们,当我复制网络帖子的链接时,它们需要用作标题,图像和url。
您可以通过meta标签实现这一目标。facebook有一个工具,您甚至可以在其中测试内容。
根据ID将meta标签动态添加到您的新闻页面。
<meta property="og:url" content="http://www.nytimes.com/2015/02/19/arts/international/when-great-minds-dont-think-alike.html" />
<meta property="og:type" content="article" />
<meta property="og:title" content="When Great Minds Don’t Think Alike" />
<meta property="og:description" content="How much does culture influence creative thinking?" />
<meta property="og:image" content="http://static01.nyt.com/images/2015/02/19/arts/international/19iht-btnumbers19A/19iht-btnumbers19A-facebookJumbo-v2.jpg" />
此处提供更多详细信息:
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句