-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
22 lines (22 loc) · 836 Bytes
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<!DOCTYPE html>
<html>
<body>
<script>
function checkUser() {
var username = document.getElementById("username").value;
var password = document.getElementById("password").value;
var correctUser = "username";
var correctPassword = "password";
if (username == correctUser && password == correctPassword) {
document.getElementById("correct").textContent = "True";
}
}
</script>
<label for="username">Username:</label>
<input type="text" id="username" name="username"><br><br>
<label for="password">Password:</label>
<input type="password" id="password" name="password"><br><br>
<button type="button" id="submit" onClick="checkUser()">Submit</button>
<label id="correct">False</label>
</body>
</html>