我正在设计一个网站,我必须从组织的facebook页面添加最后5个帖子,同样也可以从twitter上添加。现在我在网上搜索相同的内容但是没有办法继续。所以我的问题是如何为我的网站做同样的事情。 请帮帮我。
经过一番搜索,我得到了这个代码..
<iframe src="http://www.facebook.com/plugins/likebox.php?href=http%3A%2F%2Fwww.facebook.com%2FYOURPOSTURL&width=490&colorscheme=light&action=like&show_faces=true&share=true&border_color&stream=true&header=true&height=435" scrolling="yes" frameborder="0" style="border:none; overflow:hidden; width:320px; height:300px; background: white; float:left; " allowTransparency="true"></iframe>
它在我的网页上轻松显示我的facebook帖子,但我不能喜欢任何帖子。我不可能从这里喜欢它或者我错过了什么?
答案 0 :(得分:0)
对于Twitter,您可以使用嵌入式时间轴:https://dev.twitter.com/docs/embedded-timelines
对于Facebook,您可以使用JavaScript SDK(https://developers.facebook.com/docs/graph-api/reference/v2.0/page/feed/)在前端请求页面Feed(https://developers.facebook.com/docs/javascript/quickstart/v2.0),也可以在后端使用直接API调用请求。[/ p>