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

Logout after login with Facebook

I have implemented an optional login and data retrieval service using Facebook API as suggested here (this is alongside regular user registration and login service implemented in the project) :
http://devcenter.appery.io/tutorials/...

I need a mechanism for the user to logout when they are done, after logging in with Facebook. Would you have suggestions for the implementation?

Thank you.

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

Logout after login with Facebook

Hello,

We don't have ready instructions for this purpose, you can search online for Facebook logout API and implement it.

Darren Cassidy
Posts: 0
Joined: Mon Aug 11, 2014 2:10 pm

Logout after login with Facebook

Hi,

I have the same issue. Cody Blue, did you find a solution?

Alena, it seems like this is something that should be pretty basic, does your team have a solution now?

Darren

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

Logout after login with Facebook

Darren -- I clear the access_token (http://devcenter.appery.io/tutorials/...) and navigate to login page, when the user launches a logout request. Other storage variables / cache can be cleared as needed and desired, per the app functionality.

Hope this helps.

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

Logout after login with Facebook

Hi Cody,

Thanks for your update.

Unfortunatly FB does not provide logout web service.

Your solution will work for your local goals.

In additional you can try to use this functional from FB utilities.

https://developers.facebook.com/docs/...

Regards.

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

Logout after login with Facebook

Thanks for the feedback on this thread, Yurii.

Regards.

Juan Pieterse
Posts: 0
Joined: Sat Apr 25, 2015 1:47 pm

Logout after login with Facebook

how do you clear the access token?

Serhii Kulibaba
Posts: 150
Joined: Tue Aug 27, 2013 1:47 pm

Logout after login with Facebook

Hello Juan,

Please look at this documentation page: https://devcenter.appery.io/documenta...

Dongzhi Yang7528784
Posts: 0
Joined: Mon May 11, 2015 6:28 am

Logout after login with Facebook

Hi @yurri orishchuk,

Sorry to bring this up again.

I was trying to implement facebook SDK, but it doesn't seem to work in the built-in browser of appery on mobile device. It works perfect on chrome browser.
Has anyone tried successfully?
I can see on weinre that the FB object is initialized with all its functions. But calling any of its function nothing happens. i tried with the logout and the status function.

Here's what i have done.

  1. create a js file for the sdk, and copy the code between in the link below:
    https://developers.facebook.com/docs/...

  2. install the facebook plugin by appery.

  3. build a test page and with a few buttons. login, logout, detect status.

  4. set the login button using the standard appery facebook plugin.

  5. set the logout and detect status button with facebook SDK.

  6. run the app. click login button to login. after it succeeded, click the logout button and detect status button. nothing would happen for the later 2 button.

    In the end, I had to search for another solutions for facebook logout,.
    Here's the one I found.
    it worked out great for me.
    http://keganzo.blogspot.in/2012/03/wo...

    But still, Facebook SDK is very powerful tool to interact with facebook. I plan to use it in the next step. Please help to check why it is not working with the built it appery browser.

    Thanks

    Don

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

Logout after login with Facebook

Hello!

Sorre for the radio silence here. Please clear the token variables in localStorage and navigate to startscreen of your page

Return to “Issues”