added error handling support

master
LinuxMint4Ever 2020-02-20 21:43:41 +01:00
parent 5f79a49986
commit 4bd652a6e8
1 changed files with 14 additions and 2 deletions

View File

@ -19,7 +19,19 @@
<h1> <center>ThreadR</center> </h1>
</div>
<div class="item-2 round-border">
<p>Login:</p>
<p>
<?php
if (isset($_GET['error'])){
if (error == "credentials"){
echo "Invalid credentials. Try again:";
}
if (error == "session"){
echo "Your session was closed. We are sorry for the inconvenience.";
}
} else {
echo "Login:";
}
?></p>
<form action="%CONTENT_DIR%/login/redirect.php" method="post">
<input type="text" name="username" maxlength="20" placeholder="Username" />
<input type="password" name="password" maxlength="256" placeholder="Password" />
@ -30,7 +42,7 @@
</div>
<div class="item-3">
<p></p>
<a href="%CONTENT_DIR%/signup/"> <button> Registrieren </button> </a>
<a href="%CONTENT_DIR%/signup/"> <button> Register </button> </a>
<p></p>
</div>
<!-- <div class="item-4">