summaryrefslogtreecommitdiff
path: root/intern.gospeladlershof.de/check_login.php
diff options
context:
space:
mode:
authorhorus_arch2017-02-20 13:48:50 +0100
committerhorus_arch2017-02-20 13:48:50 +0100
commit5fd2250f7c9a5be373e5c71f50d0c1e001f80322 (patch)
tree4002d553fa82dbf79ca347f1ad0a3d02934b8726 /intern.gospeladlershof.de/check_login.php
parentc6cee4ef99447082d0dc64791f35cdfe40c9d810 (diff)
downloadgospeladlershof.de-5fd2250f7c9a5be373e5c71f50d0c1e001f80322.tar.gz
Testet Passwordless-Login.
Diffstat (limited to 'intern.gospeladlershof.de/check_login.php')
-rw-r--r--intern.gospeladlershof.de/check_login.php42
1 files changed, 42 insertions, 0 deletions
diff --git a/intern.gospeladlershof.de/check_login.php b/intern.gospeladlershof.de/check_login.php
new file mode 100644
index 0000000..e812a99
--- /dev/null
+++ b/intern.gospeladlershof.de/check_login.php
@@ -0,0 +1,42 @@
+<?php
+define('LOGIN_SITE', true);
+require_once __DIR__ . '/code/session.php';
+$title="Login";
+require_once __DIR__ . '/header.php';
+?>
+ <body>
+
+ <div class="container">
+
+ <form class="form-signin" method="POST" action="/code/check_login.php">
+
+<?php
+if ( ! empty($_SESSION) ) {
+ if ( isset($_SESSION["login"]) && $_SESSION["login"]){
+ header($_SERVER["SERVER_PROTOCOL"] . " 302 Redirect");
+ header("Location: /");
+ exit;
+ }
+ if ( !is_null($_SESSION["error"]) ) {
+?>
+<div class="alert alert-danger" role="alert">
+<?php
+ echo htmlentities($_SESSION["error"]);
+ unset($_SESSION["error"]);
+?>
+</div>
+<?php
+ }
+}
+?>
+ <h2 class="form-signin-heading">Login</h2>
+ <label for="inputEmail" class="sr-only">Authentifizierung</label>
+ <input name="text" type="text" id="auth_code" class="form-control" placeholder="Der Code aus der E-Mail-Adresse" required autofocus>
+ <span class="help-block">Du hast einen Code aus der E-Mail enthalten. Trag ihn hier ein.</span>
+ <button class="btn btn-lg btn-primary btn-block" type="submit">Lass mich rein</button>
+ </form>
+
+ </div> <!-- /container -->
+<?php
+require_once __DIR__ . '/footer.php';
+?>