From 9c7dc19d80dfbf85ffc7cc889c000f45637f7743 Mon Sep 17 00:00:00 2001 From: DL6ER Date: Thu, 8 Dec 2016 16:39:44 +0100 Subject: [PATCH] Add custom login page --- header.php | 10 ++-------- php/loginpage.php | 19 +++++++++++++++++++ php/password.php | 6 ++++++ 3 files changed, 27 insertions(+), 8 deletions(-) create mode 100644 php/loginpage.php diff --git a/header.php b/header.php index 6d92a4ad..0979d004 100644 --- a/header.php +++ b/header.php @@ -341,14 +341,8 @@ // // If auth is required and not set, i.e. no successfully logged in, // we show the reduced version of the summary (index) page - if(!$auth && (!isset($indexpage) || isset($_GET['login']))){ ?> - -
- Password:   -
- +
+
+ + +
+
+ +
+ + + + +
+
+
+
+
+ diff --git a/php/password.php b/php/password.php index 549771cd..1c1ce4c0 100644 --- a/php/password.php +++ b/php/password.php @@ -20,6 +20,8 @@ session_unset(); } + $wrongpassword = false; + // Test if password is set if(strlen($pwhash) > 0) { @@ -32,6 +34,10 @@ $_SESSION["hash"] = $pwhash; $auth = true; } + else + { + $wrongpassword = true; + } } // Compare auth hash with saved hash else if (isset($_SESSION["hash"]))