-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsuccess.php
97 lines (87 loc) · 2.83 KB
/
success.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
<?php
require 'config/config.php';
if (isset($_SESSION["user"])) {
$id = $_SESSION["user"];
$result = query("SELECT * FROM users WHERE id_user = $id")[0];
if ($result['roles'] == 'ADMIN') {
header("Location: admin");
} elseif($result["roles"] == 'OWNER') {
header("Location: owner");
}
}
if (!isset($_SESSION["login"]) && !isset($_SESSION["user"])) {
header("Location: login.php");
} elseif (isset($_SESSION["driver"])) {
header("Location: driver/index.php");
}
$id = $_SESSION["user"];
$user = query("SELECT * FROM users WHERE id_user = $id")[0];
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, shrink-to-fit=no"
/>
<meta name="description" content="" />
<meta name="author" content="" />
<title>Sukses Transaksi</title>
<link href="https://unpkg.com/[email protected]/dist/aos.css" rel="stylesheet" />
<link href="assets/style/main.css" rel="stylesheet" />
</head>
<body>
<div class="page-content page-success">
<div class="section-success" data-aos="zoom-in">
<div class="container">
<div class="row align-items-center row-login justify-content-center">
<div class="col-lg-6 text-center">
<img src="assets/images/icon-success.svg" alt="" />
<h2 class="mt-3">Transaction Processed!</h2>
<p>
Silahkan masuk ke "Dashboard Saya" kemudian kirim foto bukti transaksi di dahsboard transaksi anda dan
silahkan tunggu konfirmasi dari agen.
</p>
<div>
<?php if ($user["roles"] == 'ADMIN') : ?>
<a href="admin" class="btn btn-success w-50 mt-4">
My Dashboard
</a>
<?php else : ?>
<a href="user" class="btn btn-success w-50 mt-4">
Dashboard Saya
</a>
<?php endif; ?>
<a href="index.php" class="btn btn-sign-up w-50 mt-2">
Pesan Lagi
</a>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- footer -->
<footer>
<div class="container">
<div class="row">
<div class="col-12">
<p class="pt-4 pb-2">
2023 Copyright by AQUAZA. All Rights Reserved.
</p>
</div>
</div>
</div>
</footer>
<!-- akhir footer -->
<!-- Bootstrap core JavaScript -->
<script src="/vendor/jquery/jquery.slim.min.js"></script>
<script src="/vendor/bootstrap/js/bootstrap.bundle.min.js"></script>
<script src="https://unpkg.com/[email protected]/dist/aos.js"></script>
<script>
AOS.init();
</script>
<script src="/script/navbar-scroll.js"></script>
</body>
</html>