javascript - 在 Facebook API 中输入错误代码 191 - 我做错了什么?

标签 javascript facebook api error-handling feed

我刚刚尝试过,阅读了所有内容 - 但不知何故我仍然无法解决这个问题。 有人知道吗?

详情请看这里: http://i1145.photobucket.com/albums/o501/King_Coatie/notworking.gif

最佳答案

尝试加载并初始化 Javascript SDK,如下所示:

<div id="fb-root"></div>
<script>
window.fbAsyncInit = function() {
// init the FB JS SDK
FB.init({
  appId      : 'YOUR_APP_ID', // App ID from the App Dashboard
  channelUrl : '//WWW.YOUR_DOMAIN.COM/channel.html', // Channel File for x-domain communication
  status     : true, // check the login status upon init?
  cookie     : true, // set sessions cookies to allow your server to access the session?
  xfbml      : true  // parse XFBML tags on this page?
});

// Additional initialization code such as adding Event Listeners goes here

};

  // Load the SDK's source Asynchronously
(function(d, debug){
 var js, id = 'facebook-jssdk', ref = d.getElementsByTagName('script')[0];
 if (d.getElementById(id)) {return;}
 js = d.createElement('script'); js.id = id; js.async = true;
 js.src = "//connect.facebook.net/en_US/all" + (debug ? "/debug" : "") + ".js";
 ref.parentNode.insertBefore(js, ref);
 }(document, /*debug*/ false));
</script>

http://developers.facebook.com/docs/reference/javascript/

您需要向 FB 对象提供 appID,以便它识别正在处理的应用程序。

关于javascript - 在 Facebook API 中输入错误代码 191 - 我做错了什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13342538/

相关文章:

javascript - 为什么我的 javascript 中有 $ ?

javascript - `target="_blank"` 的替换?

javascript - XMLHttpRequest 无法加载 https ://www. facebook.com/dialog/oauth?response_type=code&redirect_uri=

c# - 支付给用户外部账户的银行账户给出 'No such External Account...'

api - RESTful API 身份验证/安全

javascript - Firefox - document.execCommand (‘cut’/‘copy’ ) 被拒绝,因为它不是从短时间运行的用户生成的事件处理程序中调用的

php - Facebook Jquery ajax 权限请求?

facebook - 通过新的iOS6社交框架查询Facebook用户数据

java - 如何使用java中的Twitter API获取去年至今的推文?

javascript - Jquery:在单个函数调用中单击一个元素并更改一个元素