-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathadmin-settings.php
199 lines (194 loc) · 10.9 KB
/
admin-settings.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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
<?php
session_start();
require_once('connect-db.php');
if(!isset($_SESSION['idNo'])){
header("location: authenticate.html#login");
}
if($_SESSION['uType']!="1"){
header("location: user-dashboard.php");
}
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Admin Settings</title>
<link rel="icon" type="image/png" href="./images/blue-coin.png">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link type="text/css" rel="stylesheet" href="css/materialize.css" media="screen,projection"/>
<link rel="stylesheet" type="text/css" media="screen" href="./css/style.css" />
<script type="text/javascript" src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
</head>
<body>
<nav>
<div class="nav-wrapper top-nav">
<a href="#" data-target="slide-out" class="sidenav-trigger hide-on-small-only show-on-medium-and-up"><i class="material-icons">menu</i></a>
<div class="img-hold" style="margin-top: 5px;">
<a href="./admin-dash.php" class="brand-logo"><img src="./images/p2p-logo-white-resize.png"></a>
</div>
<!--Menu Trigger on Small Screen-->
<a href="#" data-target="mobile-demo" class="sidenav-trigger"><i class="material-icons">menu</i></a>
<ul id="nav-mobile" class="right hide-on-small-only">
<li><a class="dropdown-trigger user-name" href="#" data-target="dropdown1"><?php echo $_SESSION['FName'][0];?><i class="material-icons right">arrow_drop_down</i></a></li>
</ul>
</div>
</nav>
<!--Username DropDown Items-->
<ul id="dropdown1" class="dropdown-content">
<li><a href="./admin-profile.php">My Profile<i class="material-icons left">account_circle</i></a></li>
<li><a href="./admin-settings.php">Settings<i class="material-icons left">settings</i></a></li>
<li class="divider"></li>
<li><a href="./logout.php">Logout<i class="material-icons left">power_settings_new</i></a></li>
</ul>
<!--NavBar Resize Menu-->
<ul class="sidenav" id="mobile-demo">
<li><a href="./admin-dash.php">Back to Dashboard Home<i class="material-icons">keyboard_backspace</i></a></li>
<li><a href="./user-management.php">User Management<i class="material-icons left">supervised_user_circle</i></a></li>
<li><a href="./transaction-mgmt.php">Transaction Management<i class="fas fa-money-bill left"></i></a></li>
<li><a href="./user-messages.php">User Feedback<i class="material-icons left">feedback</i></a></li>
<li><a href="./admin-settings.php">Manage Settings<i class="material-icons left">settings</i></a></li>
<li><a href="./logout.php">Logout<i class="material-icons left">power_settings_new</i></a></li>
</ul>
<!-- </div> -->
<!--Admin Side Menu Fixed-->
<ul id="slide-out" class="sidenav">
<li><a class="sidenav-close" href="#!">✕</a></li>
<li><div class="user-view">
<!-- <div class="background">
<img src="images/office.jpg">
</div> -->
<a href="./admin-settings.php"><img class="circle" src="images/default-user-icon.png"></a>
<a href="./admin-profile.php"><span class="white-text name"><?php echo $_SESSION['FName'][0];?></span></a>
<a href="./admin-settings.php"><span class="subheader white-text email"><?php echo $_SESSION['email'];?></span></a>
</div></li>
<li><a href="./admin-dash.php">Back to Dashboard Home<i class="material-icons">keyboard_backspace</i></a></li>
<li><a href="./user-management.php"><i class="material-icons">supervised_user_circle</i>User Management</a></li>
<li><a href="./transaction-mgmt.php"><i class="fas fa-money-bill"></i>Transaction Management</a></li>
<li><a href="./user-messages.php"><i class="material-icons">feedback</i>User Feedback</a></li>
<li><div class="divider"></div></li>
<li><a href="./admin-settings.php"><i class="material-icons">settings</i>Manage Settings</a></li>
<li><a class="waves-effect" href="./logout.php"><i class="material-icons">power_settings_new</i>Logout</a></li>
</ul>
<main>
<div class="center-align dashboard-title">
<h6>Edit Profile</h6>
</div>
<form>
<div class="center-align white container" id="admin-settings-container">
<div class="row">
<div class="col s5 m5 l5">
<span style="color:#494949; font-size:20px;" class="left">Profile</span>
</div>
<div class="s7 m7 l7 right-align">
<button class="btn waves-effect waves-light save-user-settings-btn" type="submit" name="save-user-changes">
Save Changes <i class="material-icons">save</i>
</button>
</div>
</div>
<div class="row">
<div class="divider"></div>
</div>
<div class="row">
<div class="col s5 m5 l5">
<span style="color:#C5C5C3; font-size:18px;">Photo</span>
</div>
<div class="input-field file-field col s7 m7 l7" id="userImageFrame">
<?php
$selectImage = "SELECT * FROM imageUpload WHERE User_ID ='{$_SESSION['idNo']}'";
$selectImageResult = $con->query($selectImage);
while($rowImage = $selectImageResult->fetch_array()){
if($rowImage['status']==0){
echo "<img src='./images/large-default-user.png' class='responsive-img left' alt='User Image'>";
}
else{
echo "<img src='./uploads/profile".$_SESSION['idNo'].".jpg?".'mt_rand'."class='responsive-img left' alt='User Image' style='max-height:200px;'>";
}
}
?>
<!-- <img src="./images/large-default-user.png" class="responsive-img left"alt="user-image"> -->
<button class="btn waves-effect waves-light change-user-image-btn">
Change<input type="file" name="new-user-img">
</button>
<div class="file-path-wrapper">
<input class="file-path validate" type="text">
</div>
</div>
</div>
<div class="row">
<div class="col s7 offset-s5">
<div class="divider"></div>
</div>
</div>
<div class="row">
<div class="col s5 m5 l5">
<span style="color:#C5C5C3; font-size:18px;">Display Name</span>
</div>
<div class="col s7 m7 l7">
<span class="left" style="color:#494949; font-size:18px;"><?php echo $_SESSION['uName']?></span>
</div>
</div>
<div class="row">
<div class="col s7 offset-s5">
<div class="divider"></div>
</div>
</div>
<div class="row">
<div class="col s5 m5 l5">
<span style="color:#C5C5C3; font-size:18px;">Email Address</span>
</div>
<div class="col s7 m7 l7">
<span class="left" style="color:#494949; font-size:18px;"><?php echo $_SESSION['email'];?></span>
</div>
</div>
<div class="row">
<div class="col s7 offset-s5">
<div class="divider"></div>
</div>
</div>
<div class="row">
<div class="col s5 m5 l5">
<span style="color:#C5C5C3; font-size:18px;">Change Password</span> <i class="grey-text material-icons">edit</i>
</div>
<div class="input-field col s7 m7 l7" id="email-field-settings">
<input type="password" name="admin-pass" class="validate" value="123456">
</div>
</div>
<div class="row">
<div class="col s5 m5 l5">
<span style="color:#C5C5C3; font-size:18px;">Re-type Password</span> <i class="grey-text material-icons">edit</i>
</div>
<div class="input-field col s7 m7 l7" id="email-field-settings">
<input type="password" name="admin-pass-retype" class="validate" value="123456">
</div>
</div>
<div class="row">
<div class="col s5 m5 l5">
<span style="color:#C5C5C3; font-size:18px;">Gender</span>
</div>
<div class="col s7 m7 l7">
<span class="left" style="color:#494949; font-size:18px;"><?php echo $_SESSION['gender'];?></span>
</div>
</div>
<div class="row">
<div class="col s7 offset-s5">
<div class="divider"></div>
</div>
</div>
</div>
</form>
</main>
<footer class="black lighten-2 page-footer" style="text-align:center; padding: 10px;">
<!-- <div class="center-align container" id="foot-logo">
<img src="./images/p2p-blue-new-layout.png" alt="company-logo">
</div> -->
<div class=" center-align container">
© 2018 StrathFund
</div>
</footer>
<script type="text/javascript" src="js/materialize.js"></script>
<script type="text/javascript" src="./js/index.js"></script>
</body>
</html>