使用开放图在 Facebook 上发布
这是 Sasikumar A,我为 Galatta 创建了应用程序,并在网页头部
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xmlns:og="http://ogp.me/ns#" xmlns:fb="https://www.facebook.com/2008/fbml">
<head>
<meta property="fb:app_id" content="123225854445872"><meta property="og:type" content="galatta-new:news"> <meta property="og:url" content="http://v3.galatta.com/tamil/news/tamannaah-the-golden-girl/39536/"><meta property="og:title" content="Tamannaah: The golden girl"> <meta property="og:description" content="Tamannaah: The golden girl"> <meta property="og:image" content="http://v3.galatta.com/community/images/logo.png"> <meta property="og:site_name" content="Galatta.com" /><meta property="og:locale" content="en_US" /></head><body><div id="fb-root"></div>{literal}<script>(function(d){ var js, id = 'facebook-jssdk'; if (d.getElementById(id)) {return;} js =d.createElement('script'); js.id = id; js.async = true; js.src = "//connect.facebook.net/en_US/all.js#appId=123225854445872&xfbml=1"; d.getElementsByTagName('head')[0].appendChild(js);}(document));</script>{/literal}<div class="fb-like" data-href="{$HTTP_REFERER}" data-send="true" data-layout="button_count" data-width="450" data-show-faces="false"
data-font="tahoma"></div></body></html>
链接中添加了以下详细信息:http://v3.galatta.com/tamil/news/tamannaah-the-golden-girl/39536/
我为 Galatta 应用程序创建了 Open Graph 操作类型、对象类型、聚合。
在操作类型中,我获得了代码 - 查看所有阅读操作:,创建新的阅读操作:,删除阅读操作:
请告诉我如何在我的网页中使用此代码。
我需要当我单击“喜欢”按钮时我需要如下结果/或如何获得以下结果。
Sasi Arjun 在 Galatta 上阅读了“Tamannaah:金色女孩”
请指导我如何在 Facebook 上发布该页面,如上面的行。
This is Sasikumar A, I created the app for Galatta and i added the following details in web page head section
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xmlns:og="http://ogp.me/ns#" xmlns:fb="https://www.facebook.com/2008/fbml">
<head>
<meta property="fb:app_id" content="123225854445872"><meta property="og:type" content="galatta-new:news"> <meta property="og:url" content="http://v3.galatta.com/tamil/news/tamannaah-the-golden-girl/39536/"><meta property="og:title" content="Tamannaah: The golden girl"> <meta property="og:description" content="Tamannaah: The golden girl"> <meta property="og:image" content="http://v3.galatta.com/community/images/logo.png"> <meta property="og:site_name" content="Galatta.com" /><meta property="og:locale" content="en_US" /></head><body><div id="fb-root"></div>{literal}<script>(function(d){ var js, id = 'facebook-jssdk'; if (d.getElementById(id)) {return;} js =d.createElement('script'); js.id = id; js.async = true; js.src = "//connect.facebook.net/en_US/all.js#appId=123225854445872&xfbml=1"; d.getElementsByTagName('head')[0].appendChild(js);}(document));</script>{/literal}<div class="fb-like" data-href="{$HTTP_REFERER}" data-send="true" data-layout="button_count" data-width="450" data-show-faces="false"
data-font="tahoma"></div></body></html>
Link : http://v3.galatta.com/tamil/news/tamannaah-the-golden-girl/39536/
I created the Open Graph action type, object type, aggregations for Galatta App.
In action type i got the code for - See all your Read actions:, Create a new Read action:, Delete a Read action:
Please tell me how to use this code in my web page.
I need while i click the Like button I need result like below / or how to work for below result.
Sasi Arjun read "Tamannaah: The golden girl" on Galatta
Please guide me how to publish the page on Facebook like above line.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这里是关于该主题的非常好的教程。
如果您询问 Open Graph Developer 工具中操作类型旁边的“代码”链接:这些仅作为示例,因为您可以通过curl 调用操作。
您的网站必须发送这些请求,例如在您的服务器上或在使用 Facebook Javascript SDK 的客户端浏览器。
Here is a really nice tutorial on exactly that topic.
If you are asking about the "code" links next to the action types in the Open Graph Developer tool: These serve just as an example, as you can invoke your actions via curl.
Your website would have to send these requests, e.g. using PHP on your server, or in the client's browser using the Facebook Javascript SDK.