Error loading Facebook PHP SDK URL while logging in
My login function is thus in Laravel
public function loginFacebook(){
$fb = new Facebook([
'app_id' => 'xxxxxxxxxxxxxxx',
'app_secret' => 'xxxxxxxxxxxxxxxxxxxxxxxx',
'default_graph_version' => 'v2.10',
]);
$helper = $fb->getRedirectLoginHelper();
$permissions = ["pages_show_list", "manage_pages", "pages_messaging", "pages_messaging_phone_number", "pages_messaging_subscriptions", "public_profile", "email"]; // Optional permissions
$loginUrl = $helper->getLoginUrl('https://teste.dev.br/login/facebook/callback', $permissions);
echo '<a href="' . $loginUrl . '">Log in with Facebook!</a>';
}
And in the App Settings you have the domain configured as shown below:
And that of the site URL.
But when squeegee, fires the following error in Facebook
Cannot Load URL: The domain of this URL is not included in the application domains. To be able to load this URL, add all the domains and subdomains to the application Domains field in the application settings.
What may be occurring?
1
Author: Tiago Ferezin, 2019-01-15