user198003
user198003

Reputation: 11151

Facebook PHP SDK logout function

can you explain to me how can i call logout function of facebook php sdk, without that logged user have to click on logout link generated with the $facebook->getLogoutUrl.

Upvotes: 1

Views: 2115

Answers (2)

Ben
Ben

Reputation: 165

Or you could use header("Location: ".$facebook->get:LogoutUrl());

That would automatically redirect the user, without them having to click anything

Curl might not work as the curl request may not have the same access token

Upvotes: 0

Vamsi Krishna B
Vamsi Krishna B

Reputation: 11490

I think theres no method to do it.. how about making a curl request for the url generated using $facebook->getLogoutUrl.

in their js api they have provided

FB.logout

http://developers.facebook.com/docs/reference/javascript/FB.logout/

Upvotes: 1

Related Questions