php delete all session if exists code example Example: clear session php <?php unset($_SESSION['counter']); ?>