-
Notifications
You must be signed in to change notification settings - Fork 2
/
addCar.php
247 lines (225 loc) · 7.42 KB
/
addCar.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
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<!-- This file has been downloaded from Bootsnipp.com. Enjoy! -->
<title>Admin Add Car Page</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css" rel="stylesheet">
<style type="text/css">
@import url('https://maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css');
@media(min-width:768px) {
body {
margin-top: 50px;
}
/*html, body, #wrapper, #page-wrapper {height: 100%; overflow: hidden;}*/
}
#wrapper {
padding-left: 0;
}
#page-wrapper {
width: 100%;
padding: 0;
background-color: #fff;
}
@media(min-width:768px) {
#wrapper {
padding-left: 225px;
}
#page-wrapper {
padding: 22px 10px;
}
}
/* Top Navigation */
.top-nav {
padding: 0 15px;
}
.top-nav>li {
display: inline-block;
float: left;
}
.top-nav>li>a {
padding-top: 20px;
padding-bottom: 20px;
line-height: 20px;
color: #fff;
}
.top-nav>li>a:hover,
.top-nav>li>a:focus,
.top-nav>.open>a,
.top-nav>.open>a:hover,
.top-nav>.open>a:focus {
color: #fff;
background-color: #1a242f;
}
.top-nav>.open>.dropdown-menu {
float: left;
position: absolute;
margin-top: 0;
/*border: 1px solid rgba(0,0,0,.15);*/
border-top-left-radius: 0;
border-top-right-radius: 0;
background-color: #fff;
-webkit-box-shadow: 0 6px 12px rgba(0,0,0,.175);
box-shadow: 0 6px 12px rgba(0,0,0,.175);
}
.top-nav>.open>.dropdown-menu>li>a {
white-space: normal;
}
/* Side Navigation */
@media(min-width:768px) {
.side-nav {
position: fixed;
top: 60px;
left: 225px;
width: 225px;
margin-left: -225px;
border: none;
border-radius: 0;
border-top: 1px rgba(0,0,0,.5) solid;
overflow-y: auto;
background-color: #222;
/*background-color: #5A6B7D;*/
bottom: 0;
overflow-x: hidden;
padding-bottom: 40px;
}
.side-nav>li>a {
width: 225px;
border-bottom: 1px rgba(0,0,0,.3) solid;
}
.side-nav li a:hover,
.side-nav li a:focus {
outline: none;
background-color: #1a242f !important;
}
}
.side-nav>li>ul {
padding: 0;
border-bottom: 1px rgba(0,0,0,.3) solid;
}
.side-nav>li>ul>li>a {
display: block;
padding: 10px 15px 10px 38px;
text-decoration: none;
/*color: #999;*/
color: #fff;
}
.side-nav>li>ul>li>a:hover {
color: #fff;
}
.navbar .nav > li > a > .label {
-webkit-border-radius: 50%;
-moz-border-radius: 50%;
border-radius: 50%;
position: absolute;
top: 14px;
right: 6px;
font-size: 10px;
font-weight: normal;
min-width: 15px;
min-height: 15px;
line-height: 1.0em;
text-align: center;
padding: 2px;
}
.navbar .nav > li > a:hover > .label {
top: 10px;
}
.navbar-brand {
padding: 5px 15px;
}
</style>
<script src="http://code.jquery.com/jquery-1.11.1.min.js"></script>
<script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>
<?php
session_start();
if(!isset($_SESSION["email"]) && $_SESSION["password"] != "") {
header("location: index.html");
}
?>
</head>
<body>
<div id="throbber" style="display:none; min-height:120px;"></div>
<div id="noty-holder"></div>
<div id="wrapper">
<!-- Navigation -->
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
<!-- Brand and toggle get grouped for better mobile display -->
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-ex1-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="adminHomepage.php">
<img src="http://placehold.it/200x50&text=HOME" alt="LOGO">
</a>
</div>
<!-- Top Menu Items -->
<ul class="nav navbar-right top-nav">
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Admin User <b class="fa fa-angle-down"></b></a>
<ul class="dropdown-menu">
<li><a href="profile.php"><i class="fa fa-fw fa-user"></i> Edit Profile</a></li>
<li class="divider"></li>
<li><a href="index.html"><i class="fa fa-fw fa-power-off"></i> Logout</a></li>
</ul>
</li>
</ul>
<!-- Sidebar Menu Items - These collapse to the responsive navigation menu on small screens -->
<div class="collapse navbar-collapse navbar-ex1-collapse">
<ul class="nav navbar-nav side-nav">
<li>
<a href="userList.php"><i class="fa fa-fw fa-user"></i> User List</a>
</li>
<li>
<a href="adminCarList.php"><i class="fa fa-fw fa-car"></i> Car List</a>
</li>
<li>
<a href="adminBookingList.php"><i class="fa fa-fw fa-book"></i> Booking List</a>
</li>
</ul>
</div>
<!-- /.navbar-collapse -->
</nav>
<div id="page-wrapper">
<div class="container-fluid">
<!-- Page Heading -->
<div class="row" id="main">
<div class="col-sm-12 col-md-12 well well-sm">
<h1>Create a Car</h1>
</div>
<div class="container">
<div class="col-sm-12 col-md-12 well well-sm text-center">
<form action="processCar.php" method="POST">
<p style="font-size: 24px">Plate: <input type="text" name="plateNumber" placeholder="Plate Number" required>
<p style="font-size: 24px; padding-right: 8px">Name: <input type="text" name="carName" placeholder="Name" required>
<p style="font-size: 24px; padding-right: 8px">Brand: <input type="text" name="brand" placeholder="Brand" required>
<p style="font-size: 24px; padding-right: 16px">Colour: <input type="text" name="colour" placeholder="Colour" required>
<p style="font-size: 24px; padding-left: 8px">Year: <input type="text" name="year" placeholder="Year" required>
</p>
<button type="submit" class="btn btn-primary" style="font-size: 24px; width: 40%" name="addButton">Register</button>
</form>
</div>
</div>
</div>
<!-- /.row -->
</div>
<!-- /.container-fluid -->
</div>
<!-- /#page-wrapper -->
</div><!-- /#wrapper -->
<script type="text/javascript">
$(function(){
$('[data-toggle="tooltip"]').tooltip();
$(".side-nav .collapse").on("hide.bs.collapse", function() {
$(this).prev().find(".fa").eq(1).removeClass("fa-angle-right").addClass("fa-angle-down");
});
$('.side-nav .collapse').on("show.bs.collapse", function() {
$(this).prev().find(".fa").eq(1).removeClass("fa-angle-down").addClass("fa-angle-right");
});
</script>
</body>
</html>