Skip to content

Instantly share code, notes, and snippets.

@niraj-shah
Created October 27, 2014 11:31
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save niraj-shah/934fbfc8c264295be74f to your computer and use it in GitHub Desktop.
Logout of Facebook PHP SDK 4.0.x session
<?php
// start session
session_start();
// kill the session
session_destroy();
// redirect back to website home
header( 'Location: http://yourwebsite.com/login' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment