【问题标题】:Publishing on facebook using open graph使用开放图在 facebook 上发布
【发布时间】:2014-02-19 04:34:16
【问题描述】:

这是 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 App 创建了 Open Graph 操作类型、对象类型、聚合。

在动作类型中,我得到了代码 - 查看所有读取动作:,创建新的读取动作:,删除读取动作:

请告诉我如何在我的网页中使用此代码。

当我单击“赞”按钮时,我需要如下所示的结果/或如何为以下结果工作。

Sasi Arjun 在 Galatta 上读到“Tamannaah:黄金女郎”

请指导我如何像上面那样在 Facebook 上发布页面。

【问题讨论】:

    标签: facebook facebook-graph-api facebook-opengraph


    【解决方案1】:

    Here 是关于该主题的非常好的教程。

    如果您询问 Open Graph Developer 工具中操作类型旁边的“代码”链接:这些只是作为示例,因为您可以通过 curl 调用您的操作。

    您的网站必须发送这些请求,例如在您的服务器上使用PHP,或者在客户端的浏览器中使用Facebook Javascript SDK

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-04-20
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-06-10
      相关资源
      最近更新 更多