How to fix the “URL blocked..” Facebook login issue
Fix the Facebook oAuth error “URL Blocked: This redirect failed because the redirect URI is not whitelisted in the app’s Client OAuth Settings. Make sure Client and Web OAuth Login are on and add all your app domains as Valid OAuth Redirect URIs.”
What is causing the error?
When you are trying to setup the Facebook login in CIMembership, and you come across this error it’s most likely because your website domain isn’t correctly whitelisted in your Facebook App.
Fixing the error:
This error indicates that there is a missing domain(s) that needs to be added to the Client OAuth Settings in your Facebook Developer app (login or setup your account at https://developers.facebook.com/).
You will need to verify that the whitelist includes all possible domains used by your organization to host social login or sharing, including secure (https), www and/or non-www domains.
Steps to solve this issue:
1) To solve this issue, Open your Facebook apps here: https://developers.facebook.com/
2) Select your app on the top right(My Apps).
3) Click on “Facebook Login >> Settings” on the left sidebar and make changes on the “Client OAuth Settings” section.
4) If you are install the CIMembership on the root of your domain, then add this URL https://www.yourdomain.com/auth/oauth2/fbcallback.html to “Valid OAuth Redirect URIs”.
5) If you are install the CIMembership in the subfolder(for eg: https://www.yourdomain.com/cimembership ) then add https://www.yourdomain.com/cimembership/auth/oauth2/fbcallback.html to “Valid OAuth Redirect URIs”.