简体   繁体   中英

Facebook Single-Sign on is not working

Developing an application using facebook. im trying to login facebook using single sign-on. Once i clicked the Facebook icon from my activity, its going to Facebook oauth page successfully. But its keep displaying the "Loading..." page. While debugging i came to know that onComplete method is not getting called. I donot know whats the root cause of the issue. Please help me. Here is my code,

        facebook.authorize(this, new String[] { "email" }, new DialogListener()
        {
            public void onComplete(Bundle values)
            {
                facebookAccessToken = facebook.getAccessToken();
                processUserInfo(facebookAccessToken);
            }

            public void onFacebookError(FacebookError e)
            {
                Log.e("FaceBook Error: ", e.toString());

            }

            public void onError(DialogError e)
            {
                Log.e("FaceBook Error: ", e.toString());

            }

            public void onCancel()
            {


            }
        });

That error usually comes up with key hashes not matching. http://developer.android.com/guide/publishing/app-signing.html Is your 4.0 a different project that maybe wasn't signed the same way the 2.3 project was?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM