mirror of
https://gitlab.com/harald.mueller/aktuelle.kurse.git
synced 2024-11-30 21:51:56 +01:00
21 lines
576 B
PHP
21 lines
576 B
PHP
|
<?php
|
||
|
session_start();
|
||
|
$user = $_SESSION['user'];
|
||
|
unset($_SESSION["user"], $_SESSION["timestamp"]);
|
||
|
$conn = mysqli_connect("localhost:3306", "root", "", "youngster_library") OR
|
||
|
die("Error " . mysqli_error($conn));
|
||
|
mysqli_set_charset($conn, 'utf8');
|
||
|
mysqli_query($conn, "UPDATE konto SET angemeldet = '0' WHERE email = '$user'");
|
||
|
if (isset($_GET['backlink'])){
|
||
|
$backlink = $_GET['backlink'];
|
||
|
if ($backlink != "bewertungen.php") {
|
||
|
header("Location: $backlink");
|
||
|
}
|
||
|
else {
|
||
|
header("Location: index.php");
|
||
|
}
|
||
|
}
|
||
|
else {
|
||
|
header("Location: index.php");
|
||
|
}
|
||
|
?>
|