Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Issue with Facebook API

I've followed all the steps in the tutorial here:
http://devcenter.appery.io/tutorials/...

After logging in with Facebook I get erroneous /me page and an OAuthExecption (screenshots are attached), and am wondering what is the reason.

Thanks in advance for your feedback.

Image Image Image

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

Issue with Facebook API

Hello Cody,

Please clarify, did you make any changes in template Facebook_helper.js or else where in your project that were not mentioned in the tutorial? This error means that access_token doesn't pass to Facebook_MeService.

Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Issue with Facebook API

Thanks for the follow-up.

I haven't made any changes to the template, and again tried reimplementing all the steps in the tutorial. I've set the start-page of my project (the only app under my appery account) to Fecebook_Login, and you may take a look.

The only deviation from the tutorial is that I am not able to set the namespace in Facebook developer account app to appery_io_app (it gives already used by some other app error): but I believe this shouldn't be the cause of issues.

Thanks in advance.

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

Issue with Facebook API

Hello Cody,

The problem is in your custom JS ClearHash. If you disable code in this script application will work properly.

Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Issue with Facebook API

Hi Evgene - Thank you very much spotting this!

Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Issue with Facebook API

Hello,

Since about a month, I haven't changed the above implementation for logging in with Facebook within my project. Things were working perfectly fine. However on testing today, I get the attached Page not found message, and there is no message on console.

What has gone wrong here?

Thank you.

Image

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Issue with Facebook API

Hi Cody -- Could you please describe what actions have you made before that error message?

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

Issue with Facebook API

Hello Cody,

Please check what redirect url you have set. Probably there are some mistakes or misprints there

Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Issue with Facebook API

Hi Evgene,

I had not made any changes to the default Facebook_Helper script, but after reviewing the present version of the tutorial again, I have changed the redirect URL code as indicated:
http://devcenter.appery.io/tutorials/...

var url = "https://www.facebook.com/dialog/oauth...=" + Facebook_Settings['client_id'] + "&redirect_uri=" + callbackUrl + "&scope=publish_actions&response_type=token";

Unfortunately, same problem - I get page not found.

What might be an issue here?

Thank you.

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Issue with Facebook API

Hi Cody,

Please check the value inside your variable 'callbackUrl' (e.g. you can call it with simple alert(); message).

Return to “Issues”