-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
78 lines (73 loc) · 3.01 KB
/
index.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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>EduBot Connect</title>
<link href="https://fonts.googleapis.com/css?family=Open+Sans" rel="stylesheet">
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet" integrity="sha384-wvfXpqpZZVQGK6TAh5PVlGOfQNHSoD2xbE+QkPxCAFlNEevoEH3Sl0sibVcOQVnN" crossorigin="anonymous">
<link rel="stylesheet" href="./style.css">
<style>
/* Add your additional CSS styles here, if needed */
.error-msg {
color: red;
display: none;
}
</style>
</head>
<body>
<div class="box-form">
<div class="left">
<div class="overlay">
<h1 style="font-family: cursive; background-image: linear-gradient(180deg, #bb4fc3, #50054e); -webkit-background-clip: text; background-clip: text; color: transparent;">Hey Scholars!</h1>
<p style="font-size: x-large;">Welcome to EduBot Connect, where learning transforms lives.</p>
</div>
</div>
<div class="right">
<h5>Login</h5>
<p>Don't have an account? <a href="#">Create Your Account</a> it takes less than a minute</p>
<div class="inputs">
<form id="login-form">
<input type="text" name="username" placeholder="username">
<br>
<input type="password" name="password" placeholder="password">
</form>
</div>
<br><br>
<div class="remember-me--forget-password">
<label>
<input type="checkbox" name="item" checked/>
<span class="text-checkbox">Remember me</span>
</label>
<p>forgot password?</p>
</div>
<br>
<button id="login-form-submit">Login</button>
<p id="login-error-msg" class="error-msg">Invalid username or password</p> <!-- Error message element -->
</div>
</div>
<!-- Your JavaScript code -->
<script>
const loginForm = document.querySelector("form"); // Select the form element
const loginButton = document.getElementById("login-form-submit");
const loginErrorMsg = document.getElementById("login-error-msg");
loginButton.addEventListener("click", (e) => {
e.preventDefault();
const username = loginForm.username.value;
const password = loginForm.password.value;
// Replace this with your actual login logic
if (username === "admin" && password === "user123") {
window.location.href = "menu1.html";
} else if (username === "paridhi_jain" && password === "paridhhii") {
window.location.href = "menu1.html";
} else if (username === "varshney_palak" && password === "varshney") {
window.location.href = "menu1.html";
} else if (username === "khushi_rathi" && password === "khhushii") {
window.location.href = "menu1.html";
} else {
// Display the error message
loginErrorMsg.style.display = "block";
}
});
</script>
</body>
</html>