-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathchangepass.php
More file actions
63 lines (40 loc) · 1.34 KB
/
changepass.php
File metadata and controls
63 lines (40 loc) · 1.34 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
59
60
61
62
63
<?php
include 'inc/header.php';
Session::CheckSession();
?>
<?php
if (isset($_GET['id'])) {
$userid = (int)$_GET['id'];
}
if ($_SERVER['REQUEST_METHOD'] == 'POST' && isset($_POST['changepass'])) {
$changePass = $users->changePasswordBysingelUserId($userid, $_POST);
}
if (isset( $changePass)) {
echo $changePass;
}
?>
<div class="card ">
<div class="card-header">
<h3>Change your password <span class="float-right"> <a href="profile.php?id=<?php ?>" class="btn btn-primary">Back</a> </h3>
</div>
<div class="card-body">
<div style="width:600px; margin:0px auto">
<form class="" action="" method="POST">
<div class="form-group">
<label for="old_password">Old Password</label>
<input type="password" name="old_password" class="form-control">
</div>
<div class="form-group">
<label for="new_password">New Password</label>
<input type="password" name="new_password" class="form-control">
</div>
<div class="form-group">
<button type="submit" name="changepass" class="btn btn-success">Change password</button>
</div>
</form>
</div>
</div>
</div>
<?php
include 'inc/footer.php';
?>