Clear PHP Session
You can completely clear the session using
the session_destroy function.
See the example:
<?php
session_destroy();
?>
A specific session variable can be deleted
using the unset function.
See the example:
<?php
unset($_SESSION['name']);
?>
Note that to clear the session, it must first
be started via session_start.