-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathforgot_password_teacher.php
More file actions
58 lines (54 loc) · 1.3 KB
/
forgot_password_teacher.php
File metadata and controls
58 lines (54 loc) · 1.3 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
49
50
51
52
53
54
55
56
57
58
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Forgot Password</title>
<script type="text/javascript" src="js/jquery-1.9.1.js"></script>
<head>
<link href='http://fonts.googleapis.com/css?family=Comfortaa' rel='stylesheet' type='text/css'>
<link rel="stylesheet" type="text/css" href="css/style.css">
<link rel="stylesheet" type="text/css" href="css/student_style.css">
</head>
<body style="overflow-y:hidden;">
<div id="header" class="header">
<ul><p><a href="index.php">NAME</a></p>
</ul>
</div>
<div id="forgot" class="forgot">
<form>
<input type="email" placeholder="Email" name="email" id="email">
<button type="button" id="login-button" onclick="sendpassword()">Send new Password</button>
</form>
</div>
<style type="text/css">
form{
left:0%;
}
</style>
</body>
</html>
<script>
function sendpassword()
{
var email=$('#email').val();
jQuery.ajax({
type: "POST",
url: "forgot-password-teacher-script.php",
data: 'email='+email,
cache: false,
success: function(response)
{
if(response==1)
{
$("#email").val("");
alert("An email has been sent to your registered email for password reset.");
}
else
{
$("#email").val("");
alert("It seems like your account is not created yet.");
}
}
})
}
</script>