forked from jmlue42/Talishar
-
Notifications
You must be signed in to change notification settings - Fork 0
/
login.php
58 lines (52 loc) · 2.23 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
<?php
include_once 'Header.php';
// Check to see if the user is logged in, and redirects to MainMenu.php if they are
if (isset($_SESSION['useruid'])) {
header("Location: /FaBOnline/MainMenu.php");
}
?>
<script src="https://accounts.google.com/gsi/client" async defer></script>
<section class="signup-form">
<h2>LOG IN</h2>
<div class="signup-form-form">
<form action="includes/login.inc.php" method="post" style='overflow:hidden;'>
<input type="text" name="uid" placeholder="Username...">
<input type="password" name="pwd" placeholder="Password...">
<label style='display:inline;' for="rememberMe">Remember Me</label>
<input style='display:inline; width:16px;' type="checkbox" checked='checked' id="rememberMe" name="rememberMe" value="rememberMe">
<button type="submit" name="submit">SUBMIT</button>
<!--
<div class="centeredGoogle">
<div id="g_id_onload" data-client_id="1089547347578-lqbvoqb0u3grqi89ibjmti2bc9lq37pr.apps.googleusercontent.com" data-login_uri="http://localhost/FaBOnline/MainMenu.php" data-auto_prompt="false">
</div>
<div class="g_id_signin" data-type="standard" data-shape="pill" data-theme="outline" data-text="signin_with" data-size="large" data-logo_alignment="left">
</div>
</div>
-->
</form>
</div>
<div class="signup-form-form">
<form action="ResetPassword.php" method="post" style='overflow:hidden;'>
<button type="submit" name="reset-password">FORGOT PASSWORD</button>
</form>
</div>
</section>
<section class='signup-form' style='position:absolute; bottom:30px; right:30px; padding: 5px;'>
<i>By using the Remember Me function, you consent to a cookie being stored in your browser for purpose of identifying your account on future visits.</i>
<div style='width:100%; text-align:center'><a href='./MenuFiles/PrivacyPolicy.php'>Privacy Policy</a></div>
</section>
</div>
<?php
// Error messages
if (isset($_GET["error"])) {
if ($_GET["error"] == "emptyinput") {
echo "<p>Fill in all fields!</p>";
} else if ($_GET["error"] == "wronglogin") {
echo "<p>Wrong login!</p>";
}
}
?>
</section>
<?php
include_once 'Footer.php';
?>