-
Notifications
You must be signed in to change notification settings - Fork 0
/
event_details.php
executable file
·136 lines (124 loc) · 9.78 KB
/
event_details.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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, shrink-to-fit=no">
<title>Book It Up</title>
<script
src="https://code.jquery.com/jquery-3.4.1.min.js"
integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo="
crossorigin="anonymous"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/css/bootstrap.min.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Montserrat:400,600,700,800">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.7.1/css/all.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/ionicons/2.0.1/css/ionicons.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/simple-line-icons/2.4.1/css/simple-line-icons.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/typicons/2.0.9/typicons.min.css">
<link rel="stylesheet" href="assets/fonts/fontawesome5-overrides.min.css">
<link rel="stylesheet" href="assets/css/styles.min.css">
</head>
<style>
.search-btn:hover
{
background-color: white;
color: black !important;
}
</style>
<?php
session_start();
if (!$_SESSION['suname']) {
header('Location: login.php');
}
?>
<body>
<nav class="navbar navbar-light navbar-expand-md navigation-clean-search" style="width: 100%;">
<div class="container"><a class="navbar-brand" href="home.php" style="font-family: Montserrat, sans-serif;">BookItUp!</a><button data-toggle="collapse" class="navbar-toggler" data-target="#navcol-1"><i class="fas fa-hamburger" style="color: white;"></i><span class="sr-only">Toggle navigation</span></button>
<div class="collapse navbar-collapse" id="navcol-1">
<form class="form-inline mr-auto" target="_self" method="POST">
<div class="form-group"><label for="search-field" style="width: 50px;"></label><input class="form-control search-field" type="search" id="search-field" name="searchEvents" placeholder="Search for locations" style="font-family: Montserrat, sans-serif;color: white;" autocomplete="on"><button class="btn btn-outline-primary btn-sm search-btn" type="submit" style="border-radius: 50%;border: none;color:white; border-color:white;" name="search"><i class="fa fa-search"></i></div>
</form>
<?php
if(isset($_POST['search']))
echo '<script>window.location.href = "search.php?search_key='.$_POST['searchEvents'].'"</script>';
?>
<?php if($_SESSION['suname'] == "admin")
echo '<ul class = "nav navbar-nav">
<li class="nav-item" role="presentation"><a class="nav-link" href="admin_panel.php" style="font-family: Montserrat, sans-serif;">Admin Panel</a></li>
</ul>'?><ul class = "nav navbar-nav">
<li class="nav-item" role="presentation"><a class="nav-link" href="history.php" style="font-family: Montserrat, sans-serif;">Purchased History</a></li>
</ul>
<ul class="nav navbar-nav">
<li class="nav-item" role="presentation"><a class="nav-link" href="cart.php" style="font-family: Montserrat, sans-serif;">Cart</a></li>
</ul>
<form method="POST">
<button class="btn btn-outline-light action-button" type="submit" role="button" name="logout" style="font-family: Montserrat, sans-serif;" data-toggle="tooltip" title="Click to logout!" data-placement="bottom" ><?php echo $_SESSION['suname']?></button>
</form>
<script>
$(document).ready(function(){
$('[data-toggle="tooltip"]').tooltip();
});
</script>
<?php
if(isset($_POST['logout'])){
session_destroy();
header("Location: login.php");
}
?>
</div>
</div>
</nav>
<div class="container">
<h3 style="font-family: Montserrat, sans-serif;"><strong>Add a new event</strong></h3>
<hr>
<form method="POST" enctype="multipart/form-data">
<div class="form-group"><input class="form-control event-name" type="text" placeholder="Name of the Event" style="border-top: none;border-left: none;border-right: none;width: 80%;" name='name' required></div>
<div class="form-group"><textarea class="form-control event-details" style="width: 80%;border-top: none;border-left: none;border-right: none;" placeholder="Details of the Event" name='details' required></textarea></div>
<div class="form-group"><input class="form-control event-language" type="text" placeholder="Language" style="border-top: none;border-left: none;border-right: none;width: 80%;" name='lang' required></div>
<div class="form-group"><input class="form-control event-language" type="text" placeholder="Genre" style="border-top: none;border-left: none;border-right: none;width: 80%;" name='genre' required></div>
<div class="form-group"><input class="form-control event-language" type="text" placeholder="Artists" style="border-top: none;border-left: none;border-right: none;width: 80%;" name='artists' required></div>
<div class="form-group"><input class="form-control event-language" type="text" placeholder="Location" style="border-top: none;border-left: none;border-right: none;width: 80%;" name='loc' required></div>
<div class="form-group"><label style="font-family: Montserrat, sans-serif;padding-left: 5px;"><strong>Min Age Limit : </strong></label><input class="form-control d-inline-block" type="number" style="width: 68%;border-top: none;border-right: none;border-left: none;" name='min_age' required></div>
<div class="form-group"><label style="font-family: Montserrat, sans-serif;padding-left: 5px;"><strong>Number of passes : </strong></label><input class="form-control d-inline-block" type="number" style="width: 68%;border-top: none;border-right: none;border-left: none;" name='passes' required></div>
<div class="form-group"><label style="font-family: Montserrat, sans-serif;padding-left: 5px;"><strong>Entry Charge : </strong></label><input class="form-control d-inline-block" type="number" style="width: 68.5%;border-top: none;border-right: none;border-left: none;" name='prices' required></div>
<div class="form-group"><label style="font-family: Montserrat, sans-serif;padding-left: 5px;"><strong>Date of the event :</strong></label><input class="form-control d-inline" type="date" style="border-left: none;border-right: none;width: 64%;border-top: none;font-family: Montserrat, sans-serif;" name="date" required></div>
<div class="form-group"><label style="font-family: Montserrat, sans-serif;padding-left: 5px;"><strong>Duration of the event: </strong></label><input class="form-control d-inline" type="time" style="border-left: none;border-right: none;width: 61%;border-top: none;font-family: Montserrat, sans-serif;" name='dur' required></div>
<div class="form-group" style="padding-left: 5px;"><label style="font-family: Montserrat, sans-serif;"><strong>Image (width: 250px, height: 300px) : </strong></label><input type="file" accept="image/*" name="img_file" required></div>
<div class="text-center"><button class="btn btn-outline-dark" type="submit" style="width: 30%;margin-top: 30px;">Add new Event</button></div>
</form>
<?php include("events_detailsPHP.php"); ?>
</div>
<div class="footer-dark" style="margin-top: 50px;">
<footer>
<div class="container">
<div class="row">
<div class="col-sm-6 col-md-3 item">
<h3>Services</h3>
<ul>
<li></li>
<li><a href="#">Offers</a></li>
<li><a href="view.php">Events</a></li>
</ul>
</div>
<div class="col-sm-6 col-md-3 item">
<h3>About</h3>
<ul>
<li></li>
<li><a href="about_us.php">Team</a></li>
<li></li>
</ul>
</div>
<div class="col-md-6 item text">
<h3>Book It Up!</h3>
<p></p>
</div>
<div class="col item social"><a href="#"><i class="icon ion-social-facebook"></i></a><a href="#"><i class="icon ion-social-twitter"></i></a><a href="#"><i class="icon ion-social-snapchat"></i></a><a href="#"><i class="icon ion-social-instagram"></i></a></div>
</div>
<p class="copyright">BookItUp! @ 2020</p>
</div>
</footer>
</div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/js/bootstrap.bundle.min.js"></script>
</body>
</html>