Game-Jaming/Backend/Controllers/Group/Logout.php

16 lines
304 B
PHP

<?php
session_start();
session_unset();
session_destroy();
$cookieCon = array(
'expires' => -1,
'samesite' => 'Strict',
'path' => '/'
);
setcookie("groupName", null, $cookieCon);
setcookie("groupId", null, $cookieCon);
setcookie("userName", null, $cookieCon);
echo http_response_code(200);