-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathverify.php
106 lines (68 loc) · 2.08 KB
/
verify.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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
<?php
session_start();
header("Location:http://127.0.0.1:5500/mainpage.html");
// if (isset($_POST['verify'])) {
$user_otp=$_POST['uotp'];
$otp=$_SESSION['otp'];
echo $otp;
if ($otp==$user_otp) {
?>
<script>
alert('Login Successful')
</script>
<?php
}
else{
?>
<script>
alert('Wrong OTP')
</script>
<?php
}
// }
?>
<!-- <!DOCTYPE html>
<html lang="en">
<head>
<title>OTP LOGIN SYSTEM USING TWILION API</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"></script>
<style>
/* Remove the navbar's default margin-bottom and rounded borders */
.navbar {
margin-bottom: 0;
border-radius: 0;
}
/* Add a gray background color and some padding to the footer */
footer {
background-color: #f2f2f2;
padding: 25px;
}
</style>
</head>
<body>
<nav class="navbar navbar-inverse">
<div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#myNavbar">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#">OTP LOGIN SYSTEM </a>
</div>
</nav>
<div class="jumbotron">
<div class="container text-center">
<form method="post" action="verify.php" >
<input type="number" name="otp">
<button type="submit" name="verify" class="btn btn-success">VERIFY</button>
</form>
</div>
</div>
</body>
</html>
-->