使用FQL代码与fb.api

using the fql code with fb.api

本文关键字:fb api 代码 FQL 使用      更新时间:2023-09-26

嘿,伙计们,我是javascript facebook SDK的新手,我正试图在个人资料相册上生成照片。

当我研究它时,我看到了解决我的解决方案的代码https://graph.facebook.com/me/fql?q=select+aid+from+album+where+owner=me()+and+type="profile"&access_token=... .

因为我新的javascript我不知道在哪里我想添加这个…但是我已经写了这样的代码

FB.api('https://graph.facebook.com/me/fql?q=select+aid+from+album+where+owner=me()+and+type="profile"&access_token=', function(response) { #somecode } );

但是这并没有给我任何输出。问题是我想在哪里添加https://graph.facebook.com/me/fql?q=select+aid+from+album+where+owner=me()+and+type="profile"&access_token=..行。

是否在FB.api路径段上?

查看https://developers.facebook.com/docs/javascript/reference/FB.api/您需要省略https://graph.facebook.com/me部分以使其工作:

FB.api("/fql?q=select+aid+from+album+where+owner=me()+and+type='profile'", function(response) { #somecode } );