将访问令牌添加到 FB.Data.query() 调用
只要不需要访问代码,我就可以毫无问题地运行一些 FQL 语句。
我想运行以下 FQL,但根据文档,它至少需要通用访问代码。
var query = FB.Data.query('SELECT eid, uid FROM event_member WHERE uid = 104821622923594');
我能够使用 php 成功创建访问令牌,并通过在浏览器中导航到该页面来访问该页面:
https://graph.facebook.com/104821622923594/events?access_token=ACCESS_TOKEN
我希望实际使用 Javascript SDK,那么如何将我生成的访问令牌添加到此 FB.Data.query要求?
I am able to run some FQL statements without problems as long as it doesn't require an access code.
I would like to run the following FQL, but according to the documentation it requires at least a generic access code.
var query = FB.Data.query('SELECT eid, uid FROM event_member WHERE uid = 104821622923594');
I am able to successfully create an access token using php and access that page by navigating to it in the browser:
https://graph.facebook.com/104821622923594/events?access_token=ACCESS_TOKEN
I was hoping to actually use the Javascript SDK, so how do I add the access token I generate to this FB.Data.query request?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
使用 FB.api 代替:
详细信息: https://developers.facebook.com/docs/reference/ JavaScript/
Use FB.api instead:
details: https://developers.facebook.com/docs/reference/javascript/