-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTask-4.html
More file actions
48 lines (48 loc) · 2.53 KB
/
Task-4.html
File metadata and controls
48 lines (48 loc) · 2.53 KB
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
<!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>Document</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-9ndCyUaIbzAi2FUVXJi0CjmCapSmO7SnpJef0486qhLnuZ2cdeRhO02iuK6FUUVM" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css" integrity="sha512-iecdLmaskl7CVkqkXNQ/ZH/XLlvWZOJyj7Yy7tcenmpD1ypASozpmT/E0iPtmFIB46ZmdtAc9eNBvH0H/ZpiBw==" crossorigin="anonymous" referrerpolicy="no-referrer" />
</head>
<body>
<form onsubmit="return validate()" class="col-auto shadow bg-body-tertiary m-auto w-25 h-100 mt-5 ps-1">
<div><h1 class="text-center mb-4 pt-5 mt-5 fst-italic">Instagram</h1></div>
<div class="input-group m-auto mb-3 ps-5 ">
<span class="input-group-text bg-dark-subtle" id="basic-addon1"><i class="fa-solid fa-user"></i></span>
<input type="text" class="border border-1 w-75 p-2" placeholder="Username" id="i1" aria-label="Username" aria-describedby="basic-addon1">
</div>
<div class="input-group mb-3 m-auto ps-5">
<span class="input-group-text bg-dark-subtle" id="basic-addon1"><i class="fa-solid fa-lock"></i></span>
<input type="password" class="border border-1 w-75 p-2" placeholder="Password" id="i2" aria-label="Username" aria-describedby="basic-addon1">
</div>
<button type="submit" class="btn btn-primary w-75 ms-5 mt-2">Log in</button>
<div class="mt-3 ms-5 pb-5">
<div class="d-inline "><input type="checkbox" class="me-1">Remember me</div>
<div class="d-inline ps-4 text-primary">Forget Password?</div>
</div>
</form>
<div class="text-center fs-6 mt-4">Don't have an account! <span class="text-primary fs-6">Sign up here.</span></div>
<script>
function validate()
{
var a=document.getElementById('i1').value
var b=document.getElementById('i2').value
if(a.length==0 && b.length==0)
alert("Enter username & Password");
else if(a.length>0 && b.length>0)
alert("logged in successfully")
else {
if(a.length==0)
alert("Enter username");
if(b.length==0)
alert("enter Password");
}
return false;
}
</script>
</body>
</html>