开发者

Can't see any of my FBJS callbacks when running on iOS

开发者 https://www.devze.com 2023-04-06 21:25 出处:网络
I\'m using a UIWebView to auth and make Facebook Graph API calls. To Log out, I\'m trying to send this:

I'm using a UIWebView to auth and make Facebook Graph API calls. To Log out, I'm trying to send this:

<div id="fb-root"></div>
<script src="http://connect.facebook.net/en_US/all.js"></script>
<script>
        FB.init({
            appId   : "01234567890..."
            status  : true,
            cookie  : true, 
            oauth: true,
            xfbml   : true
        });

        FB.getLoginStatus(function(response) {
            // nothing in here is ever called!!!
        }
</script>

but the response to getLoginStatus never gets called ... so my question is is there a better way to log out? I heard some blogs saying my 开发者_开发百科developer facebook account had to match the domain of my app. Is that the case? It's running in iOS though so how can it match?


I was never able to get this working so I just used the Graph API from the facebook iOS SDK:

https://github.com/facebook/facebook-ios-sdk

0

精彩评论

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

关注公众号