Facebook Facebook Logout - how to unlink the person from Facebook

The Login part is OK. I had to add a " Aren't you x? Click here to log in with another account " that calls the following function:

function deslogarFacebook(){

    FB.logout(function (response){

    window.location.href = "login";

}); }

It is sending back to the login screen. Facebook Facebook is still showing "continue as X" (where X is the name of the person who is logged in to Facebook) and I would like that by clicking on this button he unlocks the person from Facebook also so that he can log in with another account.

I've read the documentation from Facebook Developers but there only says that there are 3 cases as for FB.Logout but it does not explain how I do to unlink the person actually from Facebook so that they can log in with another account.

Author: WitnessTruth, 2017-08-24

1 answers

I found the solution and it was as follows. I added This code in window.fbAsyncInit:

FB.Event.subscribe("auth.logout", function(){       
    window.location = '[sua tela de login aqui]'
});

And the sign out Facebook button when the person wants to log in with another account:

<div class="fb-login-button" data-max-rows="1" data-size="large" data-button-type="continue_with" data-show-faces="false" data-auto-logout-link="true" data-use-continue-as="false"></div>
 2
Author: WitnessTruth, 2017-09-06 17:30:59