Parking Management System
Parking Management System
Group 5
Jenard Josh S. Balbin
John Alexis S. Dela Cruz
Soony B. Tomas
Christal R. Agbayani
Submitted to:
Renel F. Dumlao
Instructor I
Brief Description:
This Parking Management System was developed using PHP. It is designed to manage parking
operations by tracking parked vehicles, managing users, and organizing parking locations. Users can log
in to the system, view parking details, and manage parking categories and locations. The system provides
functionalities for administrators to oversee the management of parking slots and issue receipts upon
checkout.
Features/Components:
1. User Authentication:
- Login page (‘login.php’): Allows users and administrators to access the system securely using
session management.
2. Parking Management:
- Add, view, and manage parked vehicles, associated categories (like vehicle type), and parking
locations. This is handled in files such as ‘manage_park.php’ and ‘park_list.php’.
- The system can handle different parking locations (‘location.php’), allowing administrators to
categorize spaces based on location.
4. Category Management:
- Admins can manage vehicle categories (e.g., car, bike) through ‘manage_category.php’.
6. Dashboard:
- The main page (‘index.php’) is a dashboard showing summaries and offering navigation for
managing various system parts.
All Forms ( Pictures )
Description: The login form allows users and administrators to enter their credentials (username
and password) to access the system.
Fields:
● Username
● Password
● Login
Additional Features: Includes session handling to ensure secure access. If the login is successful,
the user is redirected to the dashboard.
2. Registration Form (likely part of ‘manage_user.php’ or ‘users.php’)
Description: Admins can create new users by providing details such as username, password, and
user role (admin/user).
Fields:
● Name
● Username
● Password
● Confirm Password
● User Type (Admin/Staff)
Description: This form is used to manage parking slots and parked vehicles, where users can
input details about vehicles and parking spaces.
Fields:
Description: The dashboard provides an overview of the system’s operations, such as the number
of parked cars, and parking locations.
Sections:
Purpose: A central hub for navigation and managing various system components.
5. Parking Location Management Form (‘manage_location.php’)
Description: Admins can add or modify parking locations (e.g., areas in a parking lot).
Fields:
● Category
● Location
● Area Capacity
● Action
This code allows administrators to add new parking records, such as vehicle details and the
location where the vehicle is parked.
< ?php
include
'db_connect.php';
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$vehicle_type = $_POST['vehicle_type'];
$location_id = $_POST['location_id'];
$license_plate = $_POST['license_plate'];
if ($qry) {
} else {
? >
Delete (Parking Record) - ‘ajax.php’
This snippet deletes a parked vehicle entry from the database based on its ID, typically through
an AJAX request.
< ?php
include
'db_connect.php';
if (isset($_POST['id'])) {
$id = $_POST['id'];
if ($qry) {
} else {
? >
Update (Parking Record) - ‘manage_park.php’
This code is used to update parking information, such as changing the location or vehicle type
for a parked vehicle.
< ?php
include
'db_connect.php';
if (isset($_POST['id'])) {
$id = $_POST['id'];
$vehicle_type = $_POST['vehicle_type'];
$location_id = $_POST['location_id'];
$license_plate = $_POST['license_plate'];
WHERE id = $id");
if ($qry) {
} else {
? >
Search (Parking Records) - ‘ajax.php’
This snippet handles searching for parked vehicles based on the license plate or vehicle type.
< ?php
include
'db_connect.php';
if (isset($_POST['search_term'])) {
$search_term = $_POST['search_term'];
$result =[];
$result[] = $row;
echo
json_encode($result);
? >
Login - ‘login.php’
This code snippet handles user authentication, checking the username and password against the
database.
<?php
include 'db_connect.php';
session_start();
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$username = $_POST['username'];
$password = $_POST['password'];
password = '$password'");
if ($qry->num_rows > 0) {
$_SESSION['login_id'] = $qry->fetch_assoc()['id'];
header("location: index.php");
} else {
?>
Logout - ‘logout.php’
This code logs the user out by destroying their session and redirecting them to the login page.
<?php
session_start();
exit();
?>
This snippet generates a receipt after a vehicle has completed parking, including the parking fee
calculation.
<?php
include 'db_connect.php';
if (isset($_GET['id'])) {
$park_data = $qry->fetch_assoc();
$parking_fee = calculate_fee($park_data['entry_time'],
$park_data['exit_time']);
?>
This snippet allows administrators to manage users, including adding or editing user information.
<?php
include 'db_connect.php';
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$username = $_POST['username'];
$password = $_POST['password'];
$role = $_POST['role'];
if (isset($_POST['id'])) {
} else {
?>
View Parked Vehicles - ‘view_parked_details.php’
This code fetches and displays details of parked vehicles, including the location and duration of
parking.
<?php
include 'db_connect.php';
?>