Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Windows Phone 8 Facebook Login Given URL is not allowed by the application

I am trying to integrate the Facebook login into my app by following the tutorial on facebooksdk.net. I am trying to use the Facebook button control.

When I click the button I get following error:

Given URL is not allowed by the Application configuration.: or more of the given URLs is not allowed by the App's settings. must match the Website URL or Canvas URL, or the domain must be a of one of the App's domains.

Screenshot for reference -

Facebook Given URL is not allowed by Application Configuration

According to some sources there is currently a bug which will prevent Facebook Login for Windows Phone from working if you do not have any entries in the "Valid OAuth redirect URIs" field in the Advanced section of your app settings. This can be worked around by adding "https://m.facebook.com/dialog/return/ms" in this field.

However that did not resolve the issue, so what else can I try to resolve this?

like image 520
kshitijgandhi Avatar asked Apr 17 '14 12:04

kshitijgandhi


2 Answers

There is a bug in Facebook and its APIs:

There is currently a bug which will prevent Facebook Login for Windows Phone from working if you have any entries in the "Valid OAuth redirect URIs" field in the Advanced section of your app settings. This can be worked around by adding "https://m.facebook.com/dialog/return/ms" in this field.

That suggestion is wrong, and you actually need to add https://www.facebook.com/ to the "Valid OAuth redirect URIs" field in the Advanced section of your app settings.

Example of setting

like image 77
kshitijgandhi Avatar answered Sep 29 '22 01:09

kshitijgandhi


I had the same issue before and I solved it by making the following changes to the app settings in developer dashboard. All you have to do is:

  1. Go to App Dashboard at developers.facebook.com
  2. Go to settings
  3. Go to Advanced Settings
  4. There is an option "Embedded browser OAuth Login" make sure it is set to "yes"

Example of embedded browser oauth login

like image 39
Joel Joseph Avatar answered Sep 29 '22 02:09

Joel Joseph