minor changes
formatting and redirect after login
This commit is contained in:
parent
26ecb2596f
commit
55450d4ff4
@ -3,7 +3,6 @@
|
||||
if(isset($_POST['tanID'])){
|
||||
//echo "Tan ->" . $_POST['tan'] . "<-";
|
||||
if($_POST['tanID'] != ""){
|
||||
addEntry();
|
||||
consumeTan($_POST['tanID']);
|
||||
}
|
||||
}
|
||||
@ -52,7 +51,7 @@
|
||||
$stmt->execute();
|
||||
$stmt->close();
|
||||
|
||||
echo "Daten eingefuegt! <br>";
|
||||
echo '<script> alert("Daten eingefuegt!"); </script>';
|
||||
|
||||
}
|
||||
|
||||
@ -93,6 +92,7 @@ function consumeTan($tanID) {
|
||||
$update = $database->query("UPDATE `tans` SET `used`= true WHERE `id` = '" . $_POST['tanID'] . "'");
|
||||
|
||||
echo "Tan verbraucht " . $_POST['tanID'];
|
||||
addEntry();
|
||||
}
|
||||
|
||||
?>
|
||||
|
@ -15,7 +15,8 @@ if( (isset($_POST['loginName'])) && isset($_POST['loginPassword'])){
|
||||
$_SESSION['user'] = $object->id;
|
||||
$_SESSION['username'] = $object->username;
|
||||
echo "Einloggen erfolgreich <br> Willkommen " . $_SESSION['username'];
|
||||
header("refresh:1;");
|
||||
//header("refresh:1;");
|
||||
header('Location: index.php?page=myFriendsBook');
|
||||
} else {
|
||||
echo "Einloggen fehlgeschlagen";
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user