1

我已成功将 html5 版本的 facebook 评论添加到我的网页中。现在我正在尝试根据文档了解如何通知新评论。我将此代码添加到正文下方顶部的脚本中。

FB.Event.subscribe('edge.create',
function(response) {
    comment.create{
    href: "",         /* Open Graph URL of the Comment Plugin */
    commentID: "",    /* The commentID of the deleted comment */
    }
  }
);

a) 我的代码是否正确 b) 我不确定在哪里添加代码 c) 我也在使用 html5 版本的评论插件,我可能需要使用 xfbml 版本吗?d) 我需要替换评论区域内的任何代码还是由 facebook 自动处理?即添加一个href url等。

4

1 回答 1

1
  1. 您应该将 'edge.create' 替换为'comment.create'
  2. 我个人还没有尝试过 HTML5 版本,但如果你愿意,我在 XFBML 版本中为此编写了一个教程
于 2011-12-17T22:15:15.313 回答