Make index page, sign up page and recover password page look better.

Bug430-Eden2
Lan Hui 2023-08-10 22:41:59 +08:00
parent 89395dbb98
commit 498f5549df
3 changed files with 28 additions and 19 deletions

View File

@ -17,7 +17,7 @@ if (isset($_SESSION["user_fullname"])) {
<div class="container"> <div class="container">
<div class="row"> <div class="row">
<div class="col"> <div class="col-md-5">
<img src="logo.png" style="width:32%; position:relative; right:-95px; top:1px;" alt="LRR Logo"> <img src="logo.png" style="width:32%; position:relative; right:-95px; top:1px;" alt="LRR Logo">
<br><br> <br><br>
<div style="width:32%; position:relative; right:-90px; font-family: Poppins-Regular;"> <div style="width:32%; position:relative; right:-90px; font-family: Poppins-Regular;">
@ -25,8 +25,9 @@ if (isset($_SESSION["user_fullname"])) {
</div> </div>
</div> </div>
<div class="col"> <div class="col-md-5">
<form method="post" action="Script.php" name="frm_login"> <form method="post" action="Script.php" name="frm_login">
<legend>Sign in</legend>
<input type="hidden" name="frm_login" value="true"/> <input type="hidden" name="frm_login" value="true"/>
<label for="user_name" class="form-label">Account name</label> <label for="user_name" class="form-label">Account name</label>
<input type="text" name="user" placeholder="Student Number / Email address" class="form-control" required="required" id="user_name" /> <input type="text" name="user" placeholder="Student Number / Email address" class="form-control" required="required" id="user_name" />

View File

@ -6,29 +6,30 @@ include 'NoDirectPhpAcess.php';
include 'Header.php'; include 'Header.php';
?> ?>
<br><br><br>
<div class="container"> <div class="container">
<div class="row justify-content-md-center"> <div class="row">
<div class="col-md-auto"> <div class="col-md-5"></div>
<div class="col-md-5">
<form method="post" action="Script.php"> <form method="post" action="Script.php">
<legend>Recover password</legend>
<input type="hidden" name="frm_recover_password" value="true"/> <input type="hidden" name="frm_recover_password" value="true"/>
Student number <input type="text" name="sno" placeholder="Enter your student number" class="form-control" required="required" value="<?php echo htmlspecialchars($_SESSION['student_number']); ?>"> Student number
<br/> <input type="text" name="sno" placeholder="Enter your student number" class="form-control" required="required" value="<?php echo htmlspecialchars($_SESSION['student_number']); ?>"> <br/>
Email <input type="text" name="email" placeholder="Enter your email address" class="form-control" required="required" value="<?php echo htmlspecialchars($_SESSION['user_email']); ?>"> Email
<br/> <input type="text" name="email" placeholder="Enter your email address" class="form-control" required="required" value="<?php echo htmlspecialchars($_SESSION['user_email']); ?>"> <br/>
<button type="submit" class="btn btn-primary">Recover</button> <button type="submit" class="btn btn-primary">Recover</button>
</form> </form>
</div> </div>
</div> </div>
<?php
<?php
if(isset($_SESSION['info_recover_password'])) { if(isset($_SESSION['info_recover_password'])) {
echo '<hr><div class="alert alert-danger" role="alert">'.htmlspecialchars($_SESSION['info_recover_password']).'</div>'; echo '<hr><div class="alert alert-danger" role="alert">'.htmlspecialchars($_SESSION['info_recover_password']).'</div>';
$_SESSION['info_recover_password'] = null; $_SESSION['info_recover_password'] = null;
} }
?> ?>
</div> </div>
<?php include 'Footer.php';?>

View File

@ -6,30 +6,38 @@ include 'NoDirectPhpAcess.php';
include 'Header.php'; include 'Header.php';
?> ?>
<br><br><br>
<div class="container"> <div class="container">
<div class="row justify-content-md-center"> <div class="row">
<div class="col-md-auto">
<div class="col-md-5"></div>
<div class="col-md-5">
<form method="post" action="Script.php" id="signup_form"> <form method="post" action="Script.php" id="signup_form">
<legend>Sign up</legend>
<input type="hidden" name="form_signup" value="true" /> <input type="hidden" name="form_signup" value="true" />
Full Name Full Name
<input type="text" name="fullname" placeholder="Your full name" class="form-control" value="<?php echo $_SESSION['user_fullname']; ?>" required="required" id="full_name"/> <input type="text" name="fullname" placeholder="Your full name" class="form-control" value="<?php echo $_SESSION['user_fullname']; ?>" required="required" id="full_name"/> <br>
Student ID Student ID
<input type="text" name="user_student_id" placeholder="Entre your student ID" class="form-control" value="<?php echo $_SESSION['user_student_id']; ?>" required="required" id="student_id"> <input type="text" name="user_student_id" placeholder="Entre your student ID" class="form-control" value="<?php echo $_SESSION['user_student_id']; ?>" required="required" id="student_id"> <br>
Email Email
<input type="text" name="email" placeholder="Email" class="form-control" value="<?php echo $_SESSION['user_email']; ?>" required="required" id="email" /> <input type="text" name="email" placeholder="Email" class="form-control" value="<?php echo $_SESSION['user_email']; ?>" required="required" id="email" /> <br>
Password <label class="form-text">must include uppercase and lowercase letters, digits and special characters</label> Password <label class="form-text">must include uppercase and lowercase letters, digits and special characters</label>
<input type="password" class="form-control" name="password" placeholder="Enter password" required="required" id="password1" /> <input type="password" class="form-control" name="password" placeholder="Enter password" required="required" id="password1" /> <br>
Confirm Password Confirm Password
<input type="password" class="form-control" name="confirmpassword" placeholder="Confirm password" required="required" id="password2" /> <input type="password" class="form-control" name="confirmpassword" placeholder="Confirm password" required="required" id="password2" /> <br>
<br> <br>
<button type="submit" class="btn btn-primary" id="signup_btn">Sign up</button> <button type="submit" class="btn btn-primary" id="signup_btn">Sign up</button>
<?php <?php
error_reporting(E_ALL); error_reporting(E_ALL);
if (isset($_SESSION['info_signup'])) { if (isset($_SESSION['info_signup'])) {
@ -43,4 +51,3 @@ include 'Header.php';
</div> </div>
</div> </div>
<?php include 'Footer.php';?>