-
Notifications
You must be signed in to change notification settings - Fork 0
/
login.html
51 lines (49 loc) · 2.17 KB
/
login.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>TrackingTime</title>
<link rel="icon" type="image/x-icon" href="https://trackingtime.co/wp-content/themes/trackingtime-v5/favicon.ico">
<link rel="stylesheet" href="./styles/login.css">
</head>
<body>
<div id="main">
<div id="bg">
<img src="https://pro.trackingtime.co/img/ui-login-background.svg" alt="">
</div>
<div id="form">
<form action="">
<div id="wrong">We could not find your account. Make sure your email and password are correct!</div>
<img src="https://trackingtime.co/wp-content/themes/trackingtime-v5/img/layout/header/logo.svg" alt=""><br>
<button><img src="https://img.icons8.com/color/48/000000/google-logo.png"/>Sign in with Google</button>
<button><img src="https://img.icons8.com/color/48/000000/microsoft.png"/>Sign in with Microsoft</button>
<button><img src="https://img.icons8.com/ios-glyphs/30/000000/mac-os.png"/>Sign in with Apple</button>
<p>----Sign in with your email----</p>
<input type="email" placeholder="Email" id="email"><br>
<input type="password" placeholder="Password" id="password"><br>
<p>Forgot your password?<u>Retrieve</u></p><br>
<input type="submit" value="LOGIN" id="sub"><br>
<a id="sign" href="./tryforfree.html">Don't have an account? SIGN UP</a>
</form>
</div>
</div>
</body>
</html>
<script>
let form=document.querySelector("form")
form.addEventListener("submit",login)
let wrong=document.querySelector("#wrong")
wrong.style.display="none"
function login(){
event.preventDefault()
let loginEmail=form.email.value
let loginPassword=form.password.value
if(loginEmail==localStorage.getItem("email") && loginPassword==localStorage.getItem("password")){
window.location.href="./table.html"
}else{
wrong.style.display=""
}
}
</script>