开发者

Facebook API search entirely JS

var url = "http://graph.facebook.com/search?q=" + keyword + "&type=post"; 
$.get(url, function(data) { etc..

Trying to pull this directly through javascript and needs to be js. I keep getting d开发者_如何学运维enied. What is the authentication for an app through JS to take care of this


Try this:

$.get('http://graph.facebook.com/search',{'q':keyword,'type':'post'}, function(data){},'javascript');

It might work--- If not, $.getScript ?


Try using the FB.api call:

FB.api('/search', {'q': keyword, 'type': 'post'}, function(response)
{
    // handle response
});
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜