【问题标题】:FBJS streemPublish not workingFBJS 流发布不工作
【发布时间】:2011-08-22 22:25:10
【问题描述】:

在我的应用程序中,我想在 facebook wall streemPublish 中发布一条短信,但它不起作用,谁能告诉我我做错了什么,否则请指导我一个很好的工作教程, 下面的代码也没有显示任何错误....

这是我的代码...

<body>
<script src="http://static.ak.connect.facebook.com/js/api_lib/v0.4/FeatureLoader.js.php" type="text/javascript"></script>

<script type="text/javascript">

function publish() {
 FB_RequireFeatures(["Connect"], function() {
   FB.Facebook.init('113700398662301', 'xd_receiver.htm');
                FB.ensureInit(function() {

                    var message = 'this is message';

                    var action_links = [{ 'text': 'Vote for Bill The Aircraft Carrier!', 'href': 'http://spayday.factor360.com/contest.html?page=viewInd&id=48082&contestId=2'}];
                    FB.Connect.streamPublish(message, action_links, null, "Share your support for Bill The Aircraft Carrier!", callback, false, null);
                });

    function callback(post_id, exception) {
        alert('Wall Post Complete');
    }

 });
}
</script>

</body>
<p>Stream Publish Test</p>
<a href="#" onclick="publish(); return false;">Post a story</a>

</html>

【问题讨论】:

    标签: facebook fbjs


    【解决方案1】:

    代码看起来有点过时了。检查此以获取有关流发布的更新信息

    https://developers.facebook.com/docs/reference/javascript/FB.ui/

    这用于设置您的 FB 初始化。

    https://developers.facebook.com/blog/post/525/

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2011-12-17
      • 1970-01-01
      • 1970-01-01
      • 2021-12-20
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多