17 lines
294 B
PHP
17 lines
294 B
PHP
<?php
|
|
// Initialize the session
|
|
session_start();
|
|
|
|
// Unset all of the session variables
|
|
$_SESSION = [];
|
|
|
|
// Destroy the session.
|
|
session_destroy();
|
|
|
|
session_start();
|
|
$_SESSION['alert'][] = ['info', 'Du har blitt logget av.'];
|
|
|
|
// Redirect to login page
|
|
header("location: login.php");
|
|
exit;
|
|
?>
|