New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How do we logout from facebook and clear access tokens as well as cookies? #20
Comments
im not sure if i quite understood ur question. do u want to logout and post as another user without exiting the app? if so u will have to use a bit of javascript to do it. another way is to logout using the facebook redirect but it is not documented. please see this on how to do it. http://stackoverflow.com/questions/2764436/facebook-oauth-logout please feel free to ask if you have any more problems. |
But, Can we use facebook javascript sdk on windows phone 7 application? i'm trying to read the link you gave..it is exactly the same prob i have, except that I cant logout of that wp7 app.. If another user tries to login, the previous user's profile still comes.. Also, can we use the Publish_Stream window by any chance ? |
how do u get the facebook access token for windows phone? u will need to use WebBrowser control inside of your app. http://msdn.microsoft.com/en-us/library/ff431797(VS.92).aspx you will need to only use JsSDK for for getting access token. after that you use Facebook# library and you can forget the webbrowser control after that. |
i use the graph oauth facebook url for getting the access token... the whole project is done on visual studio express..i am not sure how to use jsSDK with c#.. could you give me a windows phone example as to how we can use jsSDK with wp7 application. thanks :) |
first of all create a asp.net website. lets say www.fb.com/logout.aspx put this code and change neccessarily, i have comented it. so then use WebBrowser control to navigate to this url. incase you can't host the website, you mite well as trying navigating to replace yourdomain.com with the value from FacebookContext.Settings.FacebookAuthorizeUrl it basically logs you out of facebook and then again asks you to login. |
ok, now i tried the navigating the URL using WB to http://m.facebook.com/logout.php?confirm=1 i am not able to logout..it doesn't perform any action for this.. what is the yourdomain value??? getting confused regarding that.. |
get this error if I try to execute what you said:
|
next=http://yourdomain.com http://yourdomain.com should be facebookSettings.DesktopLoginUrl. you might want to change the display=popup to touch. once you logout using logout.php it will redirect to login page. that is the basic concept. |
issued solved via mails. closing. |
yes, thanks a lot, your help is appreciated :) |
You have to make the logout url manually using access key. Normally you should know the access key of the currently logged in user to logout. But without access key you will get logout url using simple steps. Here it is http://bit.ly/1UiD49I |
When I login to the facebook app on the windows phone 7 emulator, it grants an access token, and then I can post to wall and stuff..but I cant logout then..
Is there any help for this available??
I am using the graph API
The text was updated successfully, but these errors were encountered: