-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
login.php
64 lines (48 loc) · 2.63 KB
/
login.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<?php include "includes/header.php"; ?>
<?php
if (isset($_SESSION['username'])) {
header("Location: index.php");
}
?>
<link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css" rel="stylesheet" />
<br>
<br>
<br>
<section class="vh-100">
<div class="container-fluid h-custom">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-md-9 col-lg-6 col-xl-5">
<img src="https://img.freepik.com/free-vector/man-sitting-desk-unlocking-computer-computer-settings-login-flat-illustration_74855-20645.jpg?w=2000" class="img-fluid" alt="Sample image">
</div>
<div class="col-md-8 col-lg-6 col-xl-4 offset-xl-1">
<form action="includes/login.php" method="post">
<?php
if (isset($_GET["login"]) && $_GET["login"] == 'failed') {
echo
'<div class="alert alert-danger">
Incorrect Username or Password
</div>';
}
?>
<!-- Email input -->
<div class="form-outline mb-4">
<label class="form-label" for="form3Example3">Email address</label>
<input name="username" type="text" id="form3Example3" class="form-control form-control-lg" placeholder="Enter a your username" />
</div>
<!-- Password input -->
<div class="form-outline mb-3">
<label class="form-label" for="form3Example4">Password</label>
<input name="password" type="password" id="form3Example4" class="form-control form-control-lg" placeholder="Enter password" />
</div>
<div class="d-flex justify-content-between align-items-center">
<a href="forgot.php?forgot='?><?php echo uniqid(true) ?>" class="text-body">Forgot password?</a>
</div>
<div class="text-center text-lg-start mt-4 pt-2">
<button name="login" type="submit" class="btn btn-primary btn-lg" style="padding-left: 2.5rem; padding-right: 2.5rem;">Login</button>
<p class="small fw-bold mt-2 pt-1 mb-0">Don't have an account? <a href="registration.php" class="link-danger">Register</a></p>
</div>
</form>
</div>
</div>
</div>
</section>