-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprofile.php
More file actions
202 lines (191 loc) · 8.34 KB
/
Copy pathprofile.php
File metadata and controls
202 lines (191 loc) · 8.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
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
200
201
202
<?php
include "database/database.php";
include "database/connect.php";
$hasActivatedSeller = false;
session_start();
if (isset($_SESSION['userId'])) {
$userId = $_SESSION['userId'];
$userDetails = get_user_details($conn, $userId);
if ($userDetails['idRole'] != 0) {
$hasActivatedSeller = true;
}
} else {
header("Location: login.php");
}
?>
<!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">
<meta name="description" content="ShopEasily™ - Manage Your Profile">
<title>ShopEasily™ - Manage Your Profile</title>
<link rel="stylesheet" type="text/css" href="assets/css/profile.css" />
<link rel="apple-touch-icon" sizes="180x180" href="assets/favicons/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="assets/favicons/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="assets/favicons/favicon-16x16.png">
<link rel="manifest" href="assets/favicons/site.webmanifest">
<link href='https://unpkg.com/boxicons@latest/css/boxicons.min.css' rel='stylesheet'>
<link href="https://db.onlinewebfonts.com/c/48656eabd3fef6464367d956315c749a?family=Electronic+Arts+Text"
rel="stylesheet">
<link href="https://db.onlinewebfonts.com/c/cb2c6807809e3f956c87a1773338186e?family=Electronic+Arts+Text+Bold"
rel="stylesheet">
<link href="https://db.onlinewebfonts.com/c/e770a9e3ae1a8be2089472bc6391f697?family=Electronic+Arts+Display"
rel="stylesheet">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Jost:ital,wght@0,100..900;1,100..900&display=swap"
rel="stylesheet">
</head>
<body>
<header class="header" id="header">
<a href="index.php" class="logo">
<img src="assets/branding/shopeasily-logo-big.png" alt="shopeasily-logo" class="shopeasily-logo">
<img src="assets/branding/shopeasily-name-big.png" alt="shopeasily-brand" class="shopeasily-brand">
</a>
<ul class="navmenu">
<li class="homeNavButton">
<a href="index.php">
Beranda
</a>
</li>
<!--<li>
<a href="#">
Shop
</a>
</li>-->
<li class="catalogNavButton">
<a href="catalog.php">
Katalog
</a>
</li>
<!--<li>
<a href="#">
Page
</a>
</li>-->
<li class="sellerpageNavButton">
<a href="<?php if (!isset($_SESSION['userId'])) {
echo "login.php";
} else {
echo "seller.php";
} ?>">
Penjual
</a>
</li>
<div class="active-tab-indicator-line">
</div>
</ul>
<div class="nav-icon">
<div class="box">
<form action="search_results.php" class="search-for-products" method="POST">
<input type="text" class="products-search-input" name="products-search-input"
placeholder="Cari Produk di ShopEasily™....." autocorrect="off" autocapitalize="off"
autocomplete="off" required>
<button type="submit" class="search-icon-container-submit">
<i class="bx bx-search">
</i>
</button>
</form>
</div>
<a href="<?php if (!isset($_SESSION['userId'])) {
echo "login.php";
} else {
echo "cart.php";
} ?>" class="cartNavigation">
<i class="bx bx-cart">
</i>
</a>
<?php if (!isset($_SESSION['userId'])) { ?>
<a href="login.php" class="loginNavigation">
<p class="loginNavigation">Login</p>
</a>
<a href="register.php" class="registerNavigation">
<p class="registerNavigation">Register</p>
</a>
<?php } else { ?>
<a href="profile.php" class="profileNavigation">
<i class="bx bx-user">
</i>
</a>
<a href="logout.php" class="logoutNavigation">
<i class="bx bx-log-out">
</i>
</a><?php } ?>
</div>
</header>
<section class="profile">
<div class="box-profile">
<div class="info-section">
<p><strong>Nomor Identifikasi Pengguna:</strong> <?php echo $userDetails["idUser"] ?></p>
<p><strong>Nama Pengguna:</strong> <?php echo $userDetails["username"] ?></p>
<p><strong>Nama
Toko:</strong><?php if (!$hasActivatedSeller) {
echo "-";
} else {
echo $userDetails["namaToko"];
} ?><?php if (!$hasActivatedSeller) { ?><a href="seller.php">Aktifkan Fitur
Seller</a><?php } else { ?><?php } ?></p>
<p><strong>Nomor HP:</strong> <?php echo $userDetails["phoneNumber"] ?></p>
<p><strong>Alamat Email:</strong> <?php echo $userDetails["email"] ?></p>
<p><strong>Kata Sandi Akun:</strong> <?php echo $userDetails["password"] ?></p>
<a href="updateProfile.php">Ubah Detail/Kredensial Akun</a>
</div>
</div>
</section>
<footer>
<section class="contact">
<div class="contact-info">
<div class="first-info">
<img src="assets/branding/shopeasily-name.png" alt="logo-nama">
<p>3245 Grant Street Longview, <br> TX United Kingdom 765378</p>
<p>021693483404</p>
<p>kelompok1ppw@gmail.com</p>
<div class="social-icon">
<a href="https://www.facebook.com" target="_blank"><i class="bx bxl-facebook"></i></a>
<a href="https://x.com/home" target="_blank"><i class="bx bxl-twitter"></i></a>
<a href="https://www.instagram.com/" target="_blank"><i class="bx bxl-instagram"></i></a>
<a href="https://www.youtube.com/" target="_blank"><i class="bx bxl-youtube"></i></a>
<a href="https://www.linkedin.com/" target="_blank"><i class="bx bxl-linkedin"></i></a>
</div>
</div>
<div class="second-info">
<h4>Support</h4>
<p>Hubungi Kami</p>
<p>About Us</p>
<p>Size Guide</p>
<p>Shopping & Returns</p>
<p>Privacy</p>
</div>
<div class="third-info">
<h4>Shop</h4>
<p>Peripherals Gaming</p>
<p>Gadget Terkini</p>
<p>Pakaian Pria</p>
<p>Pakaian Wanita</p>
<p>Pakaian Anak-Anak</p>
</div>
<div class="fourth-info">
<h4>Perusahaan</h4>
<p>Tentang Kami</p>
<p>Blog</p>
<p>Mitra</p>
<p>Kerjasama</p>
</div>
<div class="fifth-info">
<h4>Subscribe to our newsletter</h4>
<p>Dapatkan update terkini, berbagai promo, dan diskon menarik yang dikirim langsung ke email kamu.
</p>
<p>Lorem Ipsum Dolor Sit Amet Consectetur Adispicing Elit. Eum, Debitis</p>
<p>Dapatkan update terkini, berbagai promo, dan diskon menarik yang dikirim langsung ke email kamu.
</p>
</div>
</div>
</section>
<div class="end-text">
<p>Copyright © Kelompok 1 PPW @2024. All Rights Reserved. Dibuat Oleh Kelompok 1.</p>
</div>
</footer>
</body>
</html>