0% found this document useful (0 votes)
142 views82 pages

Doctor Appoinment System

The document is a project report on the 'Doctor Appointment System' created by Akshata Harage as part of her MCA program. It outlines the system's objectives, features, and proposed modules, including patient and doctor management, appointment scheduling, and billing. The report also includes acknowledgments, an index, and various diagrams for analysis and design.

Uploaded by

akshataharage
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
142 views82 pages

Doctor Appoinment System

The document is a project report on the 'Doctor Appointment System' created by Akshata Harage as part of her MCA program. It outlines the system's objectives, features, and proposed modules, including patient and doctor management, appointment scheduling, and billing. The report also includes acknowledgments, an index, and various diagrams for analysis and design.

Uploaded by

akshataharage
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 82

A Project Report on

“Doctor Appointment system”

By

Akshata Harage
MCA – II, SEM – III
2023-2024

To
Savitribai Phule Pune University
Pune- 411041

In Partial Fulfillment of the Degree of


Master in Computer Application (M. C. A.)

Under The Guidance Of

Prof. Arati Kadam

Suryadatta Institutes of Management, Pune


Suryadatta Institute of Management and Mass Communication (SIMMC)

1
CERTIFICATE
This is to certify that Akshata Harage, has successfully completed his/her project work
entitled “Doctor Appointment System” in partial fulfillment of MCA– I Semester program
for the year A.Y. 2023-2024. He / She have worked under our guidance and direction.

Prof. Arati Kadam Dr. Manisha Kumbhar

Project Guide HOD-MCA, SGI

Examiner 1 Examiner 2

Date:

Place:

2
Acknowledgment

We are the student of MCA first year. Here by we express our thanks to our project guide for
allowing us to do the project on the Docter Appointment System This project work has
been the most exciting part of our learning experience which would be an asset for our
future carrier. We would especially like to thank our guide and mentor Prof. Arati Kadam
who constantly guided us in developing, pushing us to search for more answers to her
numerous questions. Also I would like to thank Dr. Vidya Gavekar, project coordinators
for her support. As a building block of MCA Department, I thank Dr. Manisha Kumbhar,
HOD, MCA Department for her continuous support and help. We are grateful to many
classmates who contributed their suggestions. Their hard work and examples push us to
limits of our capability and encourage us daily.

Thank You…...!

Akshata Harage

3
INDEX
Chapter Page number
CHAPTER 1 : INTRODUCTION
1.1 Existing System 8
1.2 Need for System 9
1.3 Operating Environment Hardware and Software 10
1.4 Brief Description about Technology Used
CHAPTER 2 : PROPOSED SYSTEM
2.1 Proposed System (Introduction of system) 11-12
2.2 Module specifications (Scope) 13-14
2.3 Objectives of System 14
CHAPTER 3 : ANALYSIS & DESIGN
3.1 Use Case Diagrams 15-20
3.2 Activity Diagram 21-24
3.3. Sequence Diagram 25
3.4 Class Diagram 26
3.5 Module Hierarchy Diagram 27
3.6 Table specifications (Database design) 28-33
3.7 Data dictionary 28-33
CHAPTER 4 : USER MANUAL
4.1 User Interface Screens (Input) 34-50
4.2 Output Screens with data 34-50
4.3 Data Reports
4.4 Sample program code 51-82
4.5 Limitations 83
Bibliography 83

4
1.INTRODUCTION

Chapter 1: Introduction
5
The Doctor Appointment System is a web-based application designed to streamline the
process of booking doctor appointments. It allows patients to view available doctors, select
time slots, and make appointments online. On the other hand, doctors can manage their
schedule, view appointments, and communicate with patients. This project utilizes PHP,
MySQL, HTML, CSS, and JavaScript to develop an interactive and user-friendly platform.

Project Objective

The primary objective of the Doctor Appointment System is to:


 Provide a platform for patients to book appointments online.
 Enable doctors to manage their appointments and patient details.
 Reduce the time and effort spent on manual appointment booking.
 Increase efficiency and avoid appointment conflicts.

6
Features

Admin Panel
 Login/Logout: Admin can securely log in and out of the system.
 Manage Doctors: Admin can add, edit, or delete doctors’ information (e.g., name,
specialty, contact).
 View Appointments: Admin can view all upcoming appointments and patients’
details.
 Manage Patients: Admin can manage patient records, including adding and deleting
patients.
 Reports: Admin can generate reports based on doctor availability and patient visits.
3.2 Doctor Panel
 Login/Logout: Doctors can log in to their personal dashboard.
 View Appointments: Doctors can view their scheduled appointments with patient
details.
 Manage Schedule: Doctors can set availability hours for appointments.
 Patient Communication: Doctors can communicate with patients for appointment
confirmations or updates.
3.3 Patient Panel
 Login/Registration: Patients can register or log into their account to make
appointments.
 Book Appointments: Patients can search for available doctors and book
appointments.
 View Appointments: Patients can view their upcoming and past appointments.
 Cancel Appointments: Patients can cancel appointments within a specific time frame.

1.1: Existing System

7
An existing Doctor Appointmet system typically refers to a platform or software that allows
patients to schedule appointments with healthcare providers (doctors) either online or in-
person. These systems can range from simple booking systems to fully-fledged electronic
health record (EHR) systems with advanced features. To describe the existing system, we’ll
look at its general components and functionalities, as well as its limitations.

1. Core Components of an Existing Doctor Appointment System


a. Patient Registration
 Functionality: Patients need to register in the system by providing personal
information like name, contact details, medical history, and insurance details. This
allows the system to generate a patient profile for future appointments.
 Example: A patient fills in a web form or a mobile app form with their details.
b. Doctor's Availability
 Functionality: Doctors set their availability by indicating the days and times they are
free for appointments. This allows the system to provide real-time scheduling
information.
 Example: A doctor sets their working hours (e.g., Monday to Friday from 9:00 AM to
5:00 PM).
c. Appointment Booking
 Functionality: Patients can choose a doctor, select an available time slot, and book
an appointment.
 Example: Patients select a doctor, pick an available time, and confirm the booking via
the system.
d. Notifications and Reminders
 Functionality: The system sends automated reminders (SMS, email, or push
notifications) to both patients and doctors about upcoming appointments. It also
allows for cancellations or rescheduling.
 Example: A patient receives a reminder a day before their scheduled appointment.
e. Appointment History
 Functionality: Both doctors and patients can view a history of previous
appointments, including dates, medical notes, and any follow-up actions.
 Example: A doctor can access a patient's previous consultation notes, and a patient
can view past visits in their account.

1.2: Need of the System

8
The need for a Hospital management system system arises from several factors and objectives.
Here are some key reasons why such a system is developed:

 Ability to accept the appointment by the doctor to acknowledge the patient that
their appointment has been approved.

 User should not be allowed to register if he/she tries to provide the already
registered email ID.

 The password should be encrypted and the password field shouldn't be displayed in
the admin panel.

 Implementation of pagination for all the list view across the application.

 Bug fix - Bill payment receipt contains multiple record if the patient has associated
with the same doctor multiple times.

 Addition of more fields in the prescription statement to make it more specific one.

 Addition of more details on payment - such as date of the payment made, amount
paid, etc.

 Implementation of export button in admin module to export all details to an excel


sheet.

1.3: Operating Environment

9
Hardware And Software Requirement

Hardware Requirements:

Memory Space:

 Minimum – 32 MB
 Recommended – 64 MB
 HDD – To install the software at least 2 GB and the data storage is depending upon the
organizational setup.
 PROCESSOR – Intel Pentium IV, 1GHZ or above
 RAM – 256MB or above
 VIDEO – 1024×768, 24-bit colours
 KEYBOARD – Standard 104 Keys (QWERTY)

Software Requirements:

 Operating System – WindowsXP Professional


 Developing Language – HTML, CSS, JavaScript, PHP
 DATABASE – Xampp

10
2. PROPOSED SYSTEM

2.1: Proposed System

11
Our system has the following features
Admin Panel
 Login/Logout: Admin can securely log in and out of the system.
 Manage Doctors: Admin can add, edit, or delete doctors’ information (e.g., name,
specialty, contact).
 View Appointments: Admin can view all upcoming appointments and patients’
details.
 Manage Patients: Admin can manage patient records, including adding and deleting
patients.
 Reports: Admin can generate reports based on doctor availability and patient visits.
3.2 Doctor Panel
 Login/Logout: Doctors can log in to their personal dashboard.
 View Appointments: Doctors can view their scheduled appointments with patient
details.
 Manage Schedule: Doctors can set availability hours for appointments.
 Patient Communication: Doctors can communicate with patients for appointment
confirmations or updates.
3.3 Patient Panel
 Login/Registration: Patients can register or log into their account to make
appointments.
 Book Appointments: Patients can search for available doctors and book
appointments.
 View Appointments: Patients can view their upcoming and past appointments.
 Cancel Appointments: Patients can cancel appointments within a specific time frame.

2.2: Module Specification

A Hospital Management System (HMS) is a comprehensive software solution designed to


manage all aspects of a hospital's operations, from patient care to administrative tasks.

12
Below is a detailed module specification for a Hospital Management System, which breaks
down the system into functional components and defines their purpose.

1. Patient Management Module


 Purpose: To manage patient information and interaction with the hospital.
 Core Features:
o Patient Registration: Register new patients with basic information (e.g.,
name, address, contact details, insurance info).
o Patient Profile: View and update patient information including medical
history, allergies, current medications, and previous treatments.
o Appointment Scheduling: Schedule and manage appointments between
patients and doctors.
o Patient Visit History: Record and access patient visit history and reports.
o Patient Billing: Generate bills for patients based on treatment, medications,
and services.
o Patient Discharge: Record discharge details and issue discharge summaries.
o Emergency Services: Track and respond to emergency cases, including
ambulance scheduling.
o
2. Doctor Management Module
 Purpose: To manage information and schedules for medical practitioners.
 Core Features:
o Doctor Registration: Register doctors, including personal and professional
details (e.g., qualifications, specialties, working shifts).
o Doctor Scheduling: Set working hours and manage consultation schedules for
each doctor.
o Patient Consultation: Record patient consultations and diagnosis history.
o Prescription Management: Generate prescriptions based on consultations
and diagnosis.
o Leave Management: Track and manage doctor leave requests and approvals.
o Doctor Availability: Show real-time doctor availability for patient booking.
o
3. Appointment Management Module
 Purpose: To manage appointments between patients and healthcare providers.
 Core Features:
o Appointment Scheduling: Allows patients to book appointments with doctors
or departments.
o Appointment Reminders: Automated reminders for patients regarding their
scheduled appointments.
o Appointment Rescheduling: Allows both doctors and patients to reschedule
or cancel appointments.
o Appointment History: Track and view historical data of patient appointments.
o Queue Management: Manage and display the real-time queue for
appointments to improve patient flow.

4. Billing and Payment Module


 Purpose: To manage financial transactions and payments for the services provided.

13
 Core Features:
o Invoice Generation: Generate invoices for various services like consultations,
lab tests, surgeries, etc.
o Payment Processing: Accept various payment methods (cash, credit/debit
cards, insurance claims, etc.).
o Insurance Claims: Process and track insurance claims for patients.
o Tax Management: Calculate applicable taxes on services and products.
o Payment History: Track patient payment history, including any outstanding
balances.
o Financial Reporting: Generate financial reports like revenue, expenditure, and
profit/loss statements.

5. Hospital Administration Module


 Purpose: To handle overall hospital management and administration tasks.
 Core Features:
o User Role Management: Define roles for hospital staff (admin, doctors,
nurses, pharmacists, etc.) and assign permissions.
o Access Control: Control access to sensitive data based on user roles.
o Reporting and Analytics: Generate administrative reports for hospital
performance, patient satisfaction, and resource utilization.
o Staff Payroll: Manage staff salaries, bonuses, and deductions.
o Compliance and Audits: Ensure that the hospital complies with healthcare
regulations and standards.

14
3. Analysis and Design

3.1: Use Case Diagram

1.1.1. global UseCase Diagram

15
3.1.2.Login page

16
3.1.3 appointment page

17
3.1.4 Doctor Page
18
3.1.5 : Admin page

19
3.2 Activity Diagram

20
21
3.2.1 appointment page

22
3.2.2 Doctor Page

23
3.2.3 Admin Page

24
3.3 Sequence Diagram

3.4: Class Diagram


25
26
3.5: Module Hierarchy Diagram

3.6 Data Dictionary Diagram

27
3.6.1 Patient

COLUMN DATA DESCRIPTION


S NO.
NAME TYPE CONSTRAINTS

1. P_ID Varchar(50) Primary Key Contains Unique Id

2. Name Varchar(50) - Contains Name

3. DOB Varchar(50) - Contains Date Of Birth

4. Gender Varchar(50) - Contains Gender

5. Blood Group Varchar(50) - Contains Blood Group

6. Email ID Varchar(50) - Contains Email Id

7. Address Varchar(50) - Contains Address

8. Mobile No. Integer - Contains Mobile No.

9. CGHS/Private Varchar(50) - Contains Category

28
3.6.2 Appointment

S NO. COLUMN NAME DATA TYPE CONSTRAINTS DESCRIPTION

1. P_ID Varchar(50) Primary Key Contains Unique Id


Patient

2. Specialization Varchar(50) - Contains Name of the


Department in which
Patient wants to visit

3. Doctor’s Name Varchar(50) - Contains Doctor


Name Patient Wants
To Visit

4. Consultant Fee Integer - Contains Consultant


Fee Of Doctor

5. Date Date - Contains Date For The


Appointment

6. Time Time - Contains Time For The


Appointment

29
3.6.3 Doctor

S NO. COLUMN NAME DATA TYPE CONSTRAINTS DESCRIPTION

1. D_ID Varchar(50) Primary Key Contains unique ID

2. Age Integer - Contains age

3. Gender Varchar(50) - Contains gender

4. Specialization Varchar(50) - Contains


specialization

5. Experience Varchar(50) - Contains experience


of the doctor (In
months)

6. Language Varchar(50) - Contains in how


many languages
doctor can speak.

7. Mobile No. Integer - Contains mobile


number

8. Email ID Varchar(50) - Contains Email Id

9. Schedule Varchar(50) - Contains day and


time for which the
doctor is available

30
3.6.4 Prescription

S NO. COLUMN NAME DATA TYPE CONSTRAINTS DESCRIPTION

1. D_ID Varchar(50) - Contains unique ID

2. P_ID Varchar(50) Primary Key Contains unique ID

3. Medicine Varchar(50) Contains name of the


medicine.

4. Remark Varchar(50) Contains Remark


given by the doctor
for the patient.

5. Advice Varchar(50) Contains any advice


for the patient.

31
3.6.5 Admin

COLUMN DESCRIPTION
S NO.
NAME DATA TYPE CONSTRAINTS

1. A_ID Varchar(50) Primary Key Contains unique


ID.

2. Name Varchar(50) - Contains Name

3. DOB Varchar(50) - Contains Date Of


Birth

4. Gender Varchar(50) - Contains Gender

5. Email ID Varchar(50) - Contains Email Id

6. Mobile No. Integer - Contains Mobile


No.

7. Address Varchar(50) - Contains Address

3.6.6 Bill

32
S NO. COLUMN NAME DATA TYPE CONSTRAINTS DESCRIPTION

1. P_ID Varchar(50) - Contains unique ID.

2. Bill No. Varchar(50 Primary Key Contains number of the


bill.

3. Date Varchar(50 - Contains Date of The


bill.

4. Time Varchar(50 - Contains Time of the


bill generated.

5. Amount Int - Contains amount of the


bill.

33
4.User Manual

4.1: User Interface Screen (INPUT)

Hospital Management System in php and mysql. This system has a ‘Home’ page from where the
patient, doctor & administrator can login into their accounts by toggling the tabs accordingly. Fig 1.1
shows the ‘Home’ page of our project.

34
About Us' page (Fig 1.2) allows us to get some more information about the quality and the
services of the hospital.

The ‘Home’ page consists of 3 modules:


1. Patient Module
2. Doctor Module
3. Admin Module

35
Patient Module:
This module allows patients to create their account, book an appointment to see a doctor and see
their appointment history. The registration page(in the home page itself) asks patients to enter their
First Name, Last Name, Email ID, Contact Number, Password and radio buttons to select their
gender.

Once the patient has created his/her own account after clicking the ‘Register’
button, then he will be redirected to his/her Dashboard(Fig 1.5).

36
The Dashboard page allows patients to perform two operations:

1. Book his/her appointment:

Here, the patients can able to book their appointments to see a doctor. The appointment
form(Fig 1.6) requires patients to select the doctor that they want to see, Date and Time that they
want to meet with the doctor. The consultancy fee will be shown accordingly to the patient as it was
already determined by the doctor.

After clicking on the ‘Create new entry’ button, the patient will receive an alert
that acknowledges the successful appointment of the patient.(See Fig 1.7)

37
2. View patients’ Appointment History:
Here, the patient can see their appointment history which contains Doctor
Name, Consultancy Fee, Appointment Date and Time.(See Fig 1.8).

Patient Login Page

38
Once the patient has logged out of his account, if he wants to go into his account again, he
can login his account, instead of register his account again. Fig 1.9 shows the login page.
Clicking on ‘Login’ button will redirect the patient to his dashboard page which we have
seen earlier (Fig 1.5)

This is how the patient module works. On the whole, this module allows patients to register their
account or login their account(if he/she has one), book an appointment and view his/her
appointment history.

39
Doctor Module:
The doctors can login into their account which can be done by toggling the tab from ‘Patient’ to
‘Doctor’. Fig 1.10 shows the login form for a doctor. Registration of a doctor account can be done
only by admin. We will discuss more about this in Admin Module.

Once the doctor clicking the ‘Login’ button, they will be redirected to their own dashboard which is
shown in Fig 1.11

In this page, doctor can able to see their appointments which has been booked by the patients. Fig
1.12 shows the appointment of the doctor ‘Ganesh’ which has been booked by the patient ‘Kenny

40
Sebastian’ (Fig 1.6). This means that the doctor ‘Ganesh’ will have an appointment with the patient
‘Kenny Sebastian’ on 10-10-2019 10AM.

In real-time, the doctors will have thousands of appointments. It will be easier for a doctor to search
for appointment in the case of more appointments. To make it easier, I have a ‘Search’ box in the
navigation bar (See Fig 1.12) which allows doctors to search for a patient by their contact number.
Once everything is done, the doctor can logout of their account. Thus, in general, a doctor can login
into his/her account, view their appointments and search for a patient. This is all about Doctor
Module.

Admin Module:

41
This module is the heart of our project where an admin can see the list of all patients. Doctors
and appointments and the feedback/queries received from the ‘Contact’ page. Also admin can add
doctor too. Login into admin account can be done by toggling into admin tab of the Home page.
Fig 1.13 shows the login page for admin. username: admin, password: admin123

On clicking the ‘Login’ button, the admin will be redirected to his/her dashboard as shown in Fig
1.14.

This module allows admin to perform five major operations:

42
1. View the list of all patients registered:

Admin can able to view all the patients registered. This includes the patients’ First Name, Last
Name, Email ID, Contact Number and Password. (See Fig 1.15).As like in doctor module, admin can
also search for a patient by their contact number in the search box.

43
2. View the list of all doctors registered:

Details of the doctors can also be viewed by the admin. This details include the Name of the
doctor, Password, Email and Consultancy fees, shown in Fig 1.16. Searching for a doctor can be done
by using the doctor’s Email ID in the search box.

44
3. View the Appointment lists:

Admin can also able to see the entire details of the appointment that shows the appointment
details of the patients with their respective doctors. This includes the First Name, Last Name, Email
and Contact Number of patients, doctor’s name, Appointment Date, Time and the Consultancy Fees.
(See Fig 1.17).

45
4. Add Doctor:

Admin alone can add a new doctor since anyone can register as a doctor if we put this section on
the home page. This form asks Doctor’s Name, Email ID, Password and his/her Consultancy Fees.(See
Fig 1.18)

After adding a new doctor, if we check the doctor’s list, we will see the details of new doctor is
added to the list as shown in the Fig 1.19

46
View User’s feedback/Queries:

Admin is allowed to view the feedback/Query that has been given by the user in the ‘Contact’
page (Refer Fig 1.3). This includes User’s Name, Email Id, Contact Number and the
message(Feedback/ Query) as shown in the Fig 1.20.

1. Cancel Appointments

Patients and doctors can able to delete their appointments.

If the patient deletes the last record (for doctor Ganesh), then a label "deleted by you" will be
displayed in the column 'Current Status' and the action will change to cancel state.

47
Now if we login to the doctor Ganesh's account and view his appointment details, then it will look
like this:

Similarly doctors can also delete their appointments and patients can view their updated
appointment details.

48
2. Remove Doctors by Admin

Admin can also delete the doctors from the system. This let admin to have more control over the
system.

49
4.3 Sample program code

Index page
<?php
include("header.php");
?>
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">

<!-- Bootstrap CSS -->


<link href="https://fonts.googleapis.com/css?family=IBM+Plex+Sans&display=swap"
rel="stylesheet">
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css"
integrity="sha384-/Y6pD6FV/Vv2HJnA6t+vslU6fwYXjCFtcEpHbNJ0lyAFsXTsjBbfaDjzALeQsN6
M" crossorigin="anonymous">
<link rel="stylesheet" href="vendor/fontawesome/css/font-awesome.min.css">
<link href="font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css" />

<link rel="stylesheet" type="text/css" href="style2.css">

</head>
<style type="text/css">
#inputbtn:hover{cursor:pointer;}
.card{

50
background: #f8f9fa;
border-top-left-radius: 5% 5%;
border-bottom-left-radius: 5% 5%;
border-top-right-radius: 5% 5%;
border-bottom-right-radius: 5% 5%;
}

</style>
<body style="background: -webkit-linear-gradient(left, #3931af, #00c6ff); background-size:
cover;">
<nav class="navbar navbar-expand-lg navbar-dark fixed-top" id="mainNav" >
<div class="container">

<a class="navbar-brand js-scroll-trigger" href="index.php" style="margin-top:


10px;margin-left:-65px;font-family: 'IBM Plex Sans', sans-serif;"><h4><i class="fa fa-user-
plus" aria-hidden="true"></i>&nbsp GLOBAL HOSPITALS</h4></a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-
target="#navbarResponsive" aria-controls="navbarResponsive" aria-expanded="false" aria-
label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarResponsive">
<ul class="navbar-nav ml-auto">
<li class="nav-item" style="margin-right: 40px;">
<a class="nav-link js-scroll-trigger" href="index.php" style="color: white;font-family:
'IBM Plex Sans', sans-serif;"><h6>HOME</h6></a>
</li>

<li class="nav-item" style="margin-right: 40px;">


<a class="nav-link js-scroll-trigger" href="services.html" style="color: white;font-
family: 'IBM Plex Sans', sans-serif;"><h6>ABOUT US</h6></a>
</li>

51
<li class="nav-item">
<a class="nav-link js-scroll-trigger" href="contact.html" style="color: white;font-
family: 'IBM Plex Sans', sans-serif;"><h6>CONTACT</h6></a>
</li>
</ul>
</div>
</div>
</nav>

<div class="container-fluid" style="margin-top:60px;margin-


bottom:60px;color:#34495E;">
<div class="row">

<div class="col-md-7" style="padding-left: 180px; ">


<div style="-webkit-animation: mover 2s infinite alternate;
animation: mover 1s infinite alternate;">
<img src="images/ambulance1.png" alt="" style="width: 20%;padding-left:
40px;margin-top: 150px;margin-left: 45px;margin-bottom:15px">
</div>

<div style="color: white;">


<h4 style="font-family: 'IBM Plex Sans', sans-serif;"> We are here for you!</h4>
</div>

</div>

52
<div class="col-md-4" style="margin-top: 5%;right: 8%">
<div class="card" style="font-family: 'IBM Plex Sans', sans-serif;">
<div class="card-body">
<center>
<i class="fa fa-hospital-o fa-3x" aria-hidden="true" style="color:#0062cc"></i>
<br>
<h3 style="margin-top: 10%">Patient Login</h3><br>
<form class="form-group" method="POST" action="func.php">
<div class="row" style="margin-top: 10%">
<div class="col-md-4"><label>Email-ID: </label></div>
<div class="col-md-8"><input type="text" name="email" class="form-control"
placeholder="enter email ID" required/></div><br><br>
<div class="col-md-4" style="margin-top: 8%"><label>Password: </label></div>
<div class="col-md-8" style="margin-top: 8%"><input type="password"
class="form-control" name="password2" placeholder="enter password"
required/></div><br><br><br>
</div>
<div class="row">
<div class="col-md-4" style="padding-left: 160px;margin-top: 10%">
<center><input type="submit" id="inputbtn" name="patsub" value="Login"
class="btn btn-primary"></center></div>
<!-- <div class="col-md-8" style="margin-top: 10%">
<a href="index.php" class="btn btn-primary">Back</a></div> -->
</div>
</form>
</center>
</div>
</div>
</div>

53
</div>
</div>

<!-- Optional JavaScript -->


<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-
KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN"
crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js"
integrity="sha384-b/U6ypiBEHpOf/4+1nzFpr53nxSS+GLCkfwBdFNTxtclqqenISfwAzpKaMNFN
mj4" crossorigin="anonymous"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js"
integrity="sha384-
h0AbiXch4ZDo7tp9hKZ4TsHbi047NrKGLO3SEJAg45jXxnGIfYzk4Si90RDIqNm1"
crossorigin="anonymous"></script>
</body>
</html>

Login page

54
<?php
session_start();
session_destroy();
?>
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">

<!-- Bootstrap CSS -->


<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css"
integrity="sha384-/Y6pD6FV/Vv2HJnA6t+vslU6fwYXjCFtcEpHbNJ0lyAFsXTsjBbfaDjzALeQsN6
M" crossorigin="anonymous">
<style >
.btn-outline-light:hover {
color: #0076d4;
background-color: #f8f9fa;
border-color: #f8f9fa;
}
</style>
</head>
<body style="background: -webkit-linear-gradient(left, #3931af,
#00c6ff);color:white;padding-top:100px;text-align:center;">
<h3>You have logged out.</h3><br><br>
<a href="index.php" class="btn btn-outline-light">Back to Home Page</a>
<!-- Optional JavaScript -->
<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-
KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN"
crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js"
integrity="sha384-b/U6ypiBEHpOf/4+1nzFpr53nxSS+GLCkfwBdFNTxtclqqenISfwAzpKaMNFN
mj4" crossorigin="anonymous"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js"
integrity="sha384-
h0AbiXch4ZDo7tp9hKZ4TsHbi047NrKGLO3SEJAg45jXxnGIfYzk4Si90RDIqNm1"
crossorigin="anonymous"></script>
</body>
</html>

Doctor page
<!DOCTYPE html>
<?php
include('func1.php');

55
$con=mysqli_connect("localhost","root","","myhmsdb");
$doctor = $_SESSION['dname'];
if(isset($_GET['cancel']))
{
$query=mysqli_query($con,"update appointmenttb set doctorStatus='0' where ID = '".
$_GET['ID']."'");
if($query)
{
echo "<script>alert('Your appointment successfully cancelled');</script>";
}
}

// if(isset($_GET['prescribe'])){

// $pid = $_GET['pid'];
// $ID = $_GET['ID'];
// $appdate = $_GET['appdate'];
// $apptime = $_GET['apptime'];
// $disease = $_GET['disease'];
// $allergy = $_GET['allergy'];
// $prescription = $_GET['prescription'];
// $query=mysqli_query($con,"insert into
prestb(doctor,pid,ID,appdate,apptime,disease,allergy,prescription) values ('$doctor',$pid,
$ID,'$appdate','$apptime','$disease','$allergy','$prescription');");
// if($query)
// {
// echo "<script>alert('Prescribed successfully!');</script>";
// }
// else{
// echo "<script>alert('Unable to process your request. Try again!');</script>";
// }
// }

?>
<html lang="en">
<head>

<!-- Required meta tags -->


<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<link rel="stylesheet" type="text/css" href="font-awesome-4.7.0/css/font-
awesome.min.css">
<link rel="stylesheet" href="style.css">
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="vendor/fontawesome/css/font-awesome.min.css">

56
<link rel="shortcut icon" type="image/x-icon" href="images/favicon.png" />
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css"
integrity="sha384-/Y6pD6FV/Vv2HJnA6t+vslU6fwYXjCFtcEpHbNJ0lyAFsXTsjBbfaDjzALeQsN6
M" crossorigin="anonymous">

<link rel="stylesheet"
href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2
MZw1T" crossorigin="anonymous">

<link href="https://fonts.googleapis.com/css?family=IBM+Plex+Sans&display=swap"
rel="stylesheet">
<nav class="navbar navbar-expand-lg navbar-dark bg-primary fixed-top">
<a class="navbar-brand" href="#"><i class="fa fa-user-plus" aria-hidden="true"></i> Global
Hospital </a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-
target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-
expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>

<style >
.btn-outline-light:hover{
color: #25bef7;
background-color: #f8f9fa;
border-color: #f8f9fa;
}
</style>

<style >
.bg-primary {
background: -webkit-linear-gradient(left, #3931af, #00c6ff);
}
.list-group-item.active {
z-index: 2;
color: #fff;
background-color: #342ac1;
border-color: #007bff;
}
.text-primary {
color: #342ac1!important;
}
</style>

<div class="collapse navbar-collapse" id="navbarSupportedContent">


<ul class="navbar-nav mr-auto">

57
<li class="nav-item">
<a class="nav-link" href="logout1.php"><i class="fa fa-sign-out"
aria-hidden="true"></i>Logout</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#"></a>
</li>
</ul>
<form class="form-inline my-2 my-lg-0" method="post" action="search.php">
<input class="form-control mr-sm-2" type="text" placeholder="Enter contact number"
aria-label="Search" name="contact">
<input type="submit" class="btn btn-outline-light" id="inputbtn" name="search_submit"
value="Search">
</form>
</div>
</nav>
</head>
<style type="text/css">
button:hover{cursor:pointer;}
#inputbtn:hover{cursor:pointer;}
</style>
<body style="padding-top:50px;">
<div class="container-fluid" style="margin-top:50px;">
<h3 style = "margin-left: 40%; padding-bottom: 20px;font-family:'IBM Plex Sans', sans-
serif;"> Welcome &nbsp<?php echo $_SESSION['dname'] ?> </h3>
<div class="row">
<div class="col-md-4" style="max-width:18%;margin-top: 3%;">
<div class="list-group" id="list-tab" role="tablist">
<a class="list-group-item list-group-item-action active" href="#list-dash" role="tab" aria-
controls="home" data-toggle="list">Dashboard</a>
<a class="list-group-item list-group-item-action" href="#list-app" id="list-app-list"
role="tab" data-toggle="list" aria-controls="home">Appointments</a>
<a class="list-group-item list-group-item-action" href="#list-pres" id="list-pres-list"
role="tab" data-toggle="list" aria-controls="home"> Prescription List</a>

</div><br>
</div>
<div class="col-md-8" style="margin-top: 3%;">
<div class="tab-content" id="nav-tabContent" style="width: 950px;">
<div class="tab-pane fade show active" id="list-dash" role="tabpanel" aria-
labelledby="list-dash-list">

<div class="container-fluid container-fullw bg-white" >


<div class="row">

<div class="col-sm-4" style="left: 10%">


<div class="panel panel-white no-radius text-center">

58
<div class="panel-body">
<span class="fa-stack fa-2x"> <i class="fa fa-square fa-stack-2x
text-primary"></i> <i class="fa fa-list fa-stack-1x fa-inverse"></i> </span>
<h4 class="StepTitle" style="margin-top: 5%;"> View Appointments</h4>
<script>
function clickDiv(id) {
document.querySelector(id).click();
}
</script>
<p class="links cl-effect-1">
<a href="#list-app" onclick="clickDiv('#list-app-list')">
Appointment List
</a>
</p>
</div>
</div>
</div>

<div class="col-sm-4" style="left: 15%">


<div class="panel panel-white no-radius text-center">
<div class="panel-body">
<span class="fa-stack fa-2x"> <i class="fa fa-square fa-stack-2x
text-primary"></i> <i class="fa fa-list-ul fa-stack-1x fa-inverse"></i> </span>
<h4 class="StepTitle" style="margin-top: 5%;"> Prescriptions</h4>

<p class="links cl-effect-1">


<a href="#list-pres" onclick="clickDiv('#list-pres-list')">
Prescription List
</a>
</p>
</div>
</div>
</div>

</div>
</div>
</div>

<div class="tab-pane fade" id="list-app" role="tabpanel" aria-labelledby="list-home-list">

<table class="table table-hover">


<thead>
<tr>
<th scope="col">Patient ID</th>
<th scope="col">Appointment ID</th>
<th scope="col">First Name</th>

59
<th scope="col">Last Name</th>
<th scope="col">Gender</th>
<th scope="col">Email</th>
<th scope="col">Contact</th>
<th scope="col">Appointment Date</th>
<th scope="col">Appointment Time</th>
<th scope="col">Current Status</th>
<th scope="col">Action</th>
<th scope="col">Prescribe</th>

</tr>
</thead>
<tbody>
<?php
$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;
$dname = $_SESSION['dname'];
$query = "select
pid,ID,fname,lname,gender,email,contact,appdate,apptime,userStatus,doctorStatus from
appointmenttb where doctor='$dname';";
$result = mysqli_query($con,$query);
while ($row = mysqli_fetch_array($result)){
?>
<tr>
<td><?php echo $row['pid'];?></td>
<td><?php echo $row['ID'];?></td>
<td><?php echo $row['fname'];?></td>
<td><?php echo $row['lname'];?></td>
<td><?php echo $row['gender'];?></td>
<td><?php echo $row['email'];?></td>
<td><?php echo $row['contact'];?></td>
<td><?php echo $row['appdate'];?></td>
<td><?php echo $row['apptime'];?></td>
<td>
<?php if(($row['userStatus']==1) && ($row['doctorStatus']==1))
{
echo "Active";
}
if(($row['userStatus']==0) && ($row['doctorStatus']==1))
{
echo "Cancelled by Patient";
}

if(($row['userStatus']==1) && ($row['doctorStatus']==0))


{
echo "Cancelled by You";
}

60
?></td>

<td>
<?php if(($row['userStatus']==1) && ($row['doctorStatus']==1))
{ ?>

<a href="doctor-panel.php?ID=<?php echo $row['ID']?


>&cancel=update"
onClick="return confirm('Are you sure you want to cancel this
appointment ?')"
title="Cancel Appointment" tooltip-placement="top"
tooltip="Remove"><button class="btn btn-danger">Cancel</button></a>
<?php } else {

echo "Cancelled";
} ?>

</td>

<td>

<?php if(($row['userStatus']==1) && ($row['doctorStatus']==1))


{ ?>

<a href="prescribe.php?pid=<?php echo $row['pid']?>&ID=<?php echo


$row['ID']?>&fname=<?php echo $row['fname']?>&lname=<?php echo $row['lname']?
>&appdate=<?php echo $row['appdate']?>&apptime=<?php echo $row['apptime']?>"
tooltip-placement="top" tooltip="Remove" title="prescribe">
<button class="btn btn-success">Prescibe</button></a>
<?php } else {

echo "-";
} ?>

</td>

</tr></a>
<?php } ?>
</tbody>
</table>
<br>
</div>

61
<div class="tab-pane fade" id="list-pres" role="tabpanel" aria-labelledby="list-pres-list">
<table class="table table-hover">
<thead>
<tr>

<th scope="col">Patient ID</th>

<th scope="col">First Name</th>


<th scope="col">Last Name</th>
<th scope="col">Appointment ID</th>
<th scope="col">Appointment Date</th>
<th scope="col">Appointment Time</th>
<th scope="col">Disease</th>
<th scope="col">Allergy</th>
<th scope="col">Prescribe</th>
</tr>
</thead>
<tbody>
<?php

$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;

$query = "select
pid,fname,lname,ID,appdate,apptime,disease,allergy,prescription from prestb where
doctor='$doctor';";

$result = mysqli_query($con,$query);
if(!$result){
echo mysqli_error($con);
}

while ($row = mysqli_fetch_array($result)){


?>
<tr>
<td><?php echo $row['pid'];?></td>
<td><?php echo $row['fname'];?></td>
<td><?php echo $row['lname'];?></td>
<td><?php echo $row['ID'];?></td>

<td><?php echo $row['appdate'];?></td>


<td><?php echo $row['apptime'];?></td>
<td><?php echo $row['disease'];?></td>
<td><?php echo $row['allergy'];?></td>
<td><?php echo $row['prescription'];?></td>

</tr>

62
<?php }
?>
</tbody>
</table>
</div>

<div class="tab-pane fade" id="list-app" role="tabpanel" aria-labelledby="list-pat-list">

<table class="table table-hover">


<thead>
<tr>
<th scope="col">First Name</th>
<th scope="col">Last Name</th>
<th scope="col">Email</th>
<th scope="col">Contact</th>
<th scope="col">Doctor Name</th>
<th scope="col">Consultancy Fees</th>
<th scope="col">Appointment Date</th>
<th scope="col">Appointment Time</th>
</tr>
</thead>
<tbody>
<?php

$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;

$query = "select * from appointmenttb;";


$result = mysqli_query($con,$query);
while ($row = mysqli_fetch_array($result)){

#$fname = $row['fname'];
#$lname = $row['lname'];
#$email = $row['email'];
#$contact = $row['contact'];
?>
<tr>
<td><?php echo $row['fname'];?></td>
<td><?php echo $row['lname'];?></td>
<td><?php echo $row['email'];?></td>
<td><?php echo $row['contact'];?></td>
<td><?php echo $row['doctor'];?></td>
<td><?php echo $row['docFees'];?></td>
<td><?php echo $row['appdate'];?></td>

63
<td><?php echo $row['apptime'];?></td>
</tr>
<?php } ?>
</tbody>
</table>
<br>
</div>

<div class="tab-pane fade" id="list-messages" role="tabpanel" aria-labelledby="list-


messages-list">...</div>
<div class="tab-pane fade" id="list-settings" role="tabpanel" aria-labelledby="list-
settings-list">
<form class="form-group" method="post" action="admin-panel1.php">
<div class="row">
<div class="col-md-4"><label>Doctor Name:</label></div>
<div class="col-md-8"><input type="text" class="form-control" name="doctor"
required></div><br><br>
<div class="col-md-4"><label>Password:</label></div>
<div class="col-md-8"><input type="password" class="form-control"
name="dpassword" required></div><br><br>
<div class="col-md-4"><label>Email ID:</label></div>
<div class="col-md-8"><input type="email" class="form-control" name="demail"
required></div><br><br>
<div class="col-md-4"><label>Consultancy Fees:</label></div>
<div class="col-md-8"><input type="text" class="form-control" name="docFees"
required></div><br><br>
</div>
<input type="submit" name="docsub" value="Add Doctor" class="btn btn-primary">
</form>
</div>
<div class="tab-pane fade" id="list-attend" role="tabpanel" aria-labelledby="list-attend-
list">...</div>
</div>
</div>
</div>
</div>
<!-- Optional JavaScript -->
<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-
KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN"
crossorigin="anonymous"></script>

64
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js"
integrity="sha384-b/U6ypiBEHpOf/4+1nzFpr53nxSS+GLCkfwBdFNTxtclqqenISfwAzpKaMNFN
mj4" crossorigin="anonymous"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js"
integrity="sha384-
h0AbiXch4ZDo7tp9hKZ4TsHbi047NrKGLO3SEJAg45jXxnGIfYzk4Si90RDIqNm1"
crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/limonte-sweetalert2/6.10.1/
sweetalert2.all.min.js"></script>
</body>
</html>

Doctor search
<!DOCTYPE html>
<?php #include("func.php");?>
<html>
<head>
<title>Doctor Details</title>
<link rel="shortcut icon" type="image/x-icon" href="images/favicon.png" />
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-
beta/css/bootstrap.min.css"
integrity="sha384-/Y6pD6FV/Vv2HJnA6t+vslU6fwYXjCFtcEpHbNJ0lyAFsXTsjBbfaDjzALeQsN6
M" crossorigin="anonymous">
</head>
<body>
<?php
include("newfunc.php");
if(isset($_POST['doctor_search_submit']))
{
$contact=$_POST['doctor_contact'];
$query = "select * from doctb where email= '$contact'";
$result = mysqli_query($con,$query);
$row=mysqli_fetch_array($result);
if($row['username']=="" & $row['password']=="" & $row['email']=="" &
$row['docFees']==""){
echo "<script> alert('No entries found!');
window.location.href = 'admin-panel1.php#list-doc';</script>";
}
else {
echo "<div class='container-fluid' style='margin-top:50px;'>
<div class ='card'>
<div class='card-body' style='background-color:#342ac1;color:#ffffff;'>
<table class='table table-hover'>
<thead>
<tr>
<th scope='col'>Username</th>
<th scope='col'>Password</th>

65
<th scope='col'>Email</th>
<th scope='col'>Consultancy Fees</th>
</tr>
</thead>
<tbody>";

// while ($row=mysqli_fetch_array($result)){
$username = $row['username'];
$password = $row['password'];
$email = $row['email'];
$docFees = $row['docFees'];
echo "<tr>
<td>$username</td>
<td>$password</td>
<td>$email</td>
<td>$docFees</td>
</tr>";
// }
echo "</tbody></table><center><a href='admin-panel1.php' class='btn btn-
light'>Back to dashboard</a></div></center></div></div></div>";
}
}

?>
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-
KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN"
crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js"
integrity="sha384-b/U6ypiBEHpOf/4+1nzFpr53nxSS+GLCkfwBdFNTxtclqqenISfwAzpKaMNFN
mj4" crossorigin="anonymous"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js"
integrity="sha384-
h0AbiXch4ZDo7tp9hKZ4TsHbi047NrKGLO3SEJAg45jXxnGIfYzk4Si90RDIqNm1"
crossorigin="anonymous"></script>
</body>
</html>

Admin page
<!DOCTYPE html>
<?php
$con=mysqli_connect("localhost","root","","myhmsdb");

include('newfunc.php');

if(isset($_POST['docsub']))

66
{
$doctor=$_POST['doctor'];
$dpassword=$_POST['dpassword'];
$demail=$_POST['demail'];
$spec=$_POST['special'];
$docFees=$_POST['docFees'];
$query="insert into
doctb(username,password,email,spec,docFees)values('$doctor','$dpassword','$demail','$spec','
$docFees')";
$result=mysqli_query($con,$query);
if($result)
{
echo "<script>alert('Doctor added successfully!');</script>";
}
}

if(isset($_POST['docsub1']))
{
$demail=$_POST['demail'];
$query="delete from doctb where email='$demail';";
$result=mysqli_query($con,$query);
if($result)
{
echo "<script>alert('Doctor removed successfully!');</script>";
}
else{
echo "<script>alert('Unable to delete!');</script>";
}
}

?>
<html lang="en">
<head>

<!-- Required meta tags -->


<meta charset="utf-8">
<link rel="shortcut icon" type="image/x-icon" href="images/favicon.png" />
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<link rel="stylesheet" type="text/css" href="font-awesome-4.7.0/css/font-
awesome.min.css">
<link rel="stylesheet" href="style.css">
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="vendor/fontawesome/css/font-awesome.min.css">
<link href="https://fonts.googleapis.com/css?family=IBM+Plex+Sans&display=swap"
rel="stylesheet">
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css"

67
integrity="sha384-/Y6pD6FV/Vv2HJnA6t+vslU6fwYXjCFtcEpHbNJ0lyAFsXTsjBbfaDjzA
LeQsN6M" crossorigin="anonymous">
<nav class="navbar navbar-expand-lg navbar-dark bg-primary fixed-top">

<link rel="stylesheet"
href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9Jvo
RxT2MZw1T" crossorigin="anonymous">
<a class="navbar-brand" href="#"><i class="fa fa-user-plus" aria-hidden="true"></i>
Global Hospital </a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-
target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-
expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>

<script >
var check = function() {
if (document.getElementById('dpassword').value ==
document.getElementById('cdpassword').value) {
document.getElementById('message').style.color = '#5dd05d';
document.getElementById('message').innerHTML = 'Matched';
} else {
document.getElementById('message').style.color = '#f55252';
document.getElementById('message').innerHTML = 'Not Matching';
}
}

function alphaOnly(event) {
var key = event.keyCode;
return ((key >= 65 && key <= 90) || key == 8 || key == 32);
};
</script>

<style >
.bg-primary {
background: -webkit-linear-gradient(left, #3931af, #00c6ff);
}

.col-md-4{
max-width:20% !important;
}

.list-group-item.active {
z-index: 2;
color: #fff;
background-color: #342ac1;
border-color: #007bff;
}
.text-primary {

68
color: #342ac1!important;
}

#cpass {
display: -webkit-box;
}

#list-app{
font-size:15px;
}

.btn-primary{
background-color: #3c50c1;
border-color: #3c50c1;
}
</style>

<div class="collapse navbar-collapse" id="navbarSupportedContent">


<ul class="navbar-nav mr-auto">
<li class="nav-item">
<a class="nav-link" href="logout1.php"><i class="fa fa-sign-out" aria-
hidden="true"></i>Logout</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#"></a>
</li>
</ul>
</div>
</nav>
</head>
<style type="text/css">
button:hover{cursor:pointer;}
#inputbtn:hover{cursor:pointer;}
</style>
<body style="padding-top:50px;">
<div class="container-fluid" style="margin-top:50px;">
<h3 style = "margin-left: 40%; padding-bottom: 20px;font-family: 'IBM Plex Sans', sans-
serif;"> WELCOME RECEPTIONIST </h3>
<div class="row">
<div class="col-md-4" style="max-width:25%;margin-top: 3%;">
<div class="list-group" id="list-tab" role="tablist">
<a class="list-group-item list-group-item-action active" id="list-dash-list" data-
toggle="list" href="#list-dash" role="tab" aria-controls="home">Dashboard</a>
<a class="list-group-item list-group-item-action" href="#list-doc" id="list-doc-list"
role="tab" aria-controls="home" data-toggle="list">Doctor List</a>
<a class="list-group-item list-group-item-action" href="#list-pat" id="list-pat-list"
role="tab" data-toggle="list" aria-controls="home">Patient List</a>
<a class="list-group-item list-group-item-action" href="#list-app" id="list-app-list"
role="tab" data-toggle="list" aria-controls="home">Appointment Details</a>

69
<a class="list-group-item list-group-item-action" href="#list-pres" id="list-pres-list"
role="tab" data-toggle="list" aria-controls="home">Prescription List</a>
<a class="list-group-item list-group-item-action" href="#list-settings" id="list-adoc-list"
role="tab" data-toggle="list" aria-controls="home">Add Doctor</a>
<a class="list-group-item list-group-item-action" href="#list-settings1" id="list-ddoc-list"
role="tab" data-toggle="list" aria-controls="home">Delete Doctor</a>
<a class="list-group-item list-group-item-action" href="#list-mes" id="list-mes-list"
role="tab" data-toggle="list" aria-controls="home">Queries</a>

</div><br>
</div>
<div class="col-md-8" style="margin-top: 3%;">
<div class="tab-content" id="nav-tabContent" style="width: 950px;">

<div class="tab-pane fade show active" id="list-dash" role="tabpanel" aria-


labelledby="list-dash-list">
<div class="container-fluid container-fullw bg-white" >
<div class="row">
<div class="col-sm-4">
<div class="panel panel-white no-radius text-center">
<div class="panel-body">
<span class="fa-stack fa-2x"> <i class="fa fa-square fa-stack-2x text-
primary"></i> <i class="fa fa-users fa-stack-1x fa-inverse"></i> </span>
<h4 class="StepTitle" style="margin-top: 5%;">Doctor List</h4>
<script>
function clickDiv(id) {
document.querySelector(id).click();
}
</script>
<p class="links cl-effect-1">
<a href="#list-doc" onclick="clickDiv('#list-doc-list')">
View Doctors
</a>
</p>
</div>
</div>
</div>

<div class="col-sm-4" style="left: -3%">


<div class="panel panel-white no-radius text-center">
<div class="panel-body" >
<span class="fa-stack fa-2x"> <i class="fa fa-square fa-stack-2x text-
primary"></i> <i class="fa fa-users fa-stack-1x fa-inverse"></i> </span>
<h4 class="StepTitle" style="margin-top: 5%;">Patient List</h4>

<p class="cl-effect-1">
<a href="#app-hist" onclick="clickDiv('#list-pat-list')">
View Patients

70
</a>
</p>
</div>
</div>
</div>

<div class="col-sm-4">
<div class="panel panel-white no-radius text-center">
<div class="panel-body" >
<span class="fa-stack fa-2x"> <i class="fa fa-square fa-stack-2x text-
primary"></i> <i class="fa fa-paperclip fa-stack-1x fa-inverse"></i> </span>
<h4 class="StepTitle" style="margin-top: 5%;">Appointment Details</h4>

<p class="cl-effect-1">
<a href="#app-hist" onclick="clickDiv('#list-app-list')">
View Appointments
</a>
</p>
</div>
</div>
</div>
</div>

<div class="row">
<div class="col-sm-4" style="left: 13%;margin-top: 5%;">
<div class="panel panel-white no-radius text-center">
<div class="panel-body" >
<span class="fa-stack fa-2x"> <i class="fa fa-square fa-stack-2x text-
primary"></i> <i class="fa fa-list-ul fa-stack-1x fa-inverse"></i> </span>
<h4 class="StepTitle" style="margin-top: 5%;">Prescription List</h4>

<p class="cl-effect-1">
<a href="#list-pres" onclick="clickDiv('#list-pres-list')">
View Prescriptions
</a>
</p>
</div>
</div>
</div>

<div class="col-sm-4" style="left: 18%;margin-top: 5%">


<div class="panel panel-white no-radius text-center">
<div class="panel-body" >
<span class="fa-stack fa-2x"> <i class="fa fa-square fa-stack-2x text-
primary"></i> <i class="fa fa-plus fa-stack-1x fa-inverse"></i> </span>
<h4 class="StepTitle" style="margin-top: 5%;">Manage Doctors</h4>

<p class="cl-effect-1">

71
<a href="#app-hist" onclick="clickDiv('#list-adoc-list')">Add Doctors</a>
&nbsp|
<a href="#app-hist" onclick="clickDiv('#list-ddoc-list')">
Delete Doctors
</a>
</p>
</div>
</div>
</div>
</div>

</div>
</div>

<div class="tab-pane fade" id="list-doc" role="tabpanel" aria-labelledby="list-home-


list">

<div class="col-md-8">
<form class="form-group" action="doctorsearch.php" method="post">
<div class="row">
<div class="col-md-10"><input type="text" name="doctor_contact" placeholder="Enter
Email ID" class = "form-control"></div>
<div class="col-md-2"><input type="submit" name="doctor_search_submit" class="btn
btn-primary" value="Search"></div></div>
</form>
</div>
<table class="table table-hover">
<thead>
<tr>
<th scope="col">Doctor Name</th>
<th scope="col">Specialization</th>
<th scope="col">Email</th>
<th scope="col">Password</th>
<th scope="col">Fees</th>
</tr>
</thead>
<tbody>
<?php

72
$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;
$query = "select * from doctb";
$result = mysqli_query($con,$query);
while ($row = mysqli_fetch_array($result)){
$username = $row['username'];
$spec = $row['spec'];
$email = $row['email'];
$password = $row['password'];
$docFees = $row['docFees'];

echo "<tr>
<td>$username</td>
<td>$spec</td>
<td>$email</td>
<td>$password</td>
<td>$docFees</td>
</tr>";
}

?>
</tbody>
</table>
<br>
</div>

<div class="tab-pane fade" id="list-pat" role="tabpanel" aria-labelledby="list-pat-list">

<div class="col-md-8">
<form class="form-group" action="patientsearch.php" method="post">
<div class="row">
<div class="col-md-10"><input type="text" name="patient_contact" placeholder="Enter
Contact" class = "form-control"></div>
<div class="col-md-2"><input type="submit" name="patient_search_submit" class="btn
btn-primary" value="Search"></div></div>
</form>
</div>

<table class="table table-hover">


<thead>
<tr>
<th scope="col">Patient ID</th>
<th scope="col">First Name</th>
<th scope="col">Last Name</th>
<th scope="col">Gender</th>
<th scope="col">Email</th>
<th scope="col">Contact</th>
<th scope="col">Password</th>
</tr>

73
</thead>
<tbody>
<?php
$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;
$query = "select * from patreg";
$result = mysqli_query($con,$query);
while ($row = mysqli_fetch_array($result)){
$pid = $row['pid'];
$fname = $row['fname'];
$lname = $row['lname'];
$gender = $row['gender'];
$email = $row['email'];
$contact = $row['contact'];
$password = $row['password'];

echo "<tr>
<td>$pid</td>
<td>$fname</td>
<td>$lname</td>
<td>$gender</td>
<td>$email</td>
<td>$contact</td>
<td>$password</td>
</tr>";
}

?>
</tbody>
</table>
<br>
</div>

<div class="tab-pane fade" id="list-pres" role="tabpanel" aria-labelledby="list-pres-list">

<div class="col-md-8">

<div class="row">

<table class="table table-hover">


<thead>
<tr>
<th scope="col">Doctor</th>
<th scope="col">Patient ID</th>
<th scope="col">Appointment ID</th>
<th scope="col">First Name</th>
<th scope="col">Last Name</th>

74
<th scope="col">Appointment Date</th>
<th scope="col">Appointment Time</th>
<th scope="col">Disease</th>
<th scope="col">Allergy</th>
<th scope="col">Prescription</th>
</tr>
</thead>
<tbody>
<?php
$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;
$query = "select * from prestb";
$result = mysqli_query($con,$query);
while ($row = mysqli_fetch_array($result)){
$doctor = $row['doctor'];
$pid = $row['pid'];
$ID = $row['ID'];
$fname = $row['fname'];
$lname = $row['lname'];
$appdate = $row['appdate'];
$apptime = $row['apptime'];
$disease = $row['disease'];
$allergy = $row['allergy'];
$pres = $row['prescription'];

echo "<tr>
<td>$doctor</td>
<td>$pid</td>
<td>$ID</td>
<td>$fname</td>
<td>$lname</td>
<td>$appdate</td>
<td>$apptime</td>
<td>$disease</td>
<td>$allergy</td>
<td>$pres</td>
</tr>";
}

?>
</tbody>
</table>
<br>
</div>
</div>
</div>

75
<div class="tab-pane fade" id="list-app" role="tabpanel" aria-labelledby="list-pat-list">

<div class="col-md-8">
<form class="form-group" action="appsearch.php" method="post">
<div class="row">
<div class="col-md-10"><input type="text" name="app_contact" placeholder="Enter
Contact" class = "form-control"></div>
<div class="col-md-2"><input type="submit" name="app_search_submit" class="btn
btn-primary" value="Search"></div></div>
</form>
</div>

<table class="table table-hover">


<thead>
<tr>
<th scope="col">Appointment ID</th>
<th scope="col">Patient ID</th>
<th scope="col">First Name</th>
<th scope="col">Last Name</th>
<th scope="col">Gender</th>
<th scope="col">Email</th>
<th scope="col">Contact</th>
<th scope="col">Doctor Name</th>
<th scope="col">Consultancy Fees</th>
<th scope="col">Appointment Date</th>
<th scope="col">Appointment Time</th>
<th scope="col">Appointment Status</th>
</tr>
</thead>
<tbody>
<?php

$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;

$query = "select * from appointmenttb;";


$result = mysqli_query($con,$query);
while ($row = mysqli_fetch_array($result)){
?>
<tr>
<td><?php echo $row['ID'];?></td>
<td><?php echo $row['pid'];?></td>
<td><?php echo $row['fname'];?></td>
<td><?php echo $row['lname'];?></td>
<td><?php echo $row['gender'];?></td>
<td><?php echo $row['email'];?></td>
<td><?php echo $row['contact'];?></td>
<td><?php echo $row['doctor'];?></td>
<td><?php echo $row['docFees'];?></td>

76
<td><?php echo $row['appdate'];?></td>
<td><?php echo $row['apptime'];?></td>
<td>
<?php if(($row['userStatus']==1) && ($row['doctorStatus']==1))
{
echo "Active";
}
if(($row['userStatus']==0) && ($row['doctorStatus']==1))
{
echo "Cancelled by Patient";
}

if(($row['userStatus']==1) && ($row['doctorStatus']==0))


{
echo "Cancelled by Doctor";
}
?></td>
</tr>
<?php } ?>
</tbody>
</table>
<br>
</div>

<div class="tab-pane fade" id="list-messages" role="tabpanel" aria-labelledby="list-


messages-list">...</div>

<div class="tab-pane fade" id="list-settings" role="tabpanel" aria-labelledby="list-


settings-list">
<form class="form-group" method="post" action="admin-panel1.php">
<div class="row">
<div class="col-md-4"><label>Doctor Name:</label></div>
<div class="col-md-8"><input type="text" class="form-control" name="doctor"
onkeydown="return alphaOnly(event);" required></div><br><br>
<div class="col-md-4"><label>Specialization:</label></div>
<div class="col-md-8">
<select name="special" class="form-control" id="special" required="required">
<option value="head" name="spec" disabled selected>Select
Specialization</option>
<option value="General" name="spec">General</option>
<option value="Cardiologist" name="spec">Cardiologist</option>
<option value="Neurologist" name="spec">Neurologist</option>
<option value="Pediatrician" name="spec">Pediatrician</option>
</select>
</div><br><br>
<div class="col-md-4"><label>Email ID:</label></div>
<div class="col-md-8"><input type="email" class="form-control"
name="demail" required></div><br><br>
<div class="col-md-4"><label>Password:</label></div>

77
<div class="col-md-8"><input type="password" class="form-control"
onkeyup='check();' name="dpassword" id="dpassword" required></div><br><br>
<div class="col-md-4"><label>Confirm Password:</label></div>
<div class="col-md-8" id='cpass'><input type="password" class="form-control"
onkeyup='check();' name="cdpassword" id="cdpassword" required>&nbsp &nbsp<span
id='message'></span> </div><br><br>

<div class="col-md-4"><label>Consultancy Fees:</label></div>


<div class="col-md-8"><input type="text" class="form-control"
name="docFees" required></div><br><br>
</div>
<input type="submit" name="docsub" value="Add Doctor" class="btn btn-primary">
</form>
</div>

<div class="tab-pane fade" id="list-settings1" role="tabpanel" aria-labelledby="list-


settings1-list">
<form class="form-group" method="post" action="admin-panel1.php">
<div class="row">

<div class="col-md-4"><label>Email ID:</label></div>


<div class="col-md-8"><input type="email" class="form-control"
name="demail" required></div><br><br>

</div>
<input type="submit" name="docsub1" value="Delete Doctor" class="btn btn-
primary" onclick="confirm('do you really want to delete?')">
</form>
</div>

<div class="tab-pane fade" id="list-attend" role="tabpanel" aria-labelledby="list-attend-


list">...</div>

<div class="tab-pane fade" id="list-mes" role="tabpanel" aria-labelledby="list-mes-


list">

<div class="col-md-8">
<form class="form-group" action="messearch.php" method="post">
<div class="row">
<div class="col-md-10"><input type="text" name="mes_contact" placeholder="Enter
Contact" class = "form-control"></div>
<div class="col-md-2"><input type="submit" name="mes_search_submit" class="btn
btn-primary" value="Search"></div></div>
</form>
</div>

<table class="table table-hover">


<thead>

78
<tr>
<th scope="col">User Name</th>
<th scope="col">Email</th>
<th scope="col">Contact</th>
<th scope="col">Message</th>
</tr>
</thead>
<tbody>
<?php

$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;

$query = "select * from contact;";


$result = mysqli_query($con,$query);
while ($row = mysqli_fetch_array($result)){

#$fname = $row['fname'];
#$lname = $row['lname'];
#$email = $row['email'];
#$contact = $row['contact'];
?>
<tr>
<td><?php echo $row['name'];?></td>
<td><?php echo $row['email'];?></td>
<td><?php echo $row['contact'];?></td>
<td><?php echo $row['message'];?></td>
</tr>
<?php } ?>
</tbody>
</table>
<br>
</div>

</div>
</div>
</div>
</div>
<!-- Optional JavaScript -->
<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-
KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN"
crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js"
integrity="sha384-b/U6ypiBEHpOf/4+1nzFpr53nxSS+GLCkfwBdFNTxtclqqenISfwAzpKa
MNFNmj4" crossorigin="anonymous"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js"
integrity="sha384-

79
h0AbiXch4ZDo7tp9hKZ4TsHbi047NrKGLO3SEJAg45jXxnGIfYzk4Si90RDIqNm1"
crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/limonte-sweetalert2/6.10.1/
sweetalert2.all.min.js"></script>
</body>
</html>

Logout page
<?php
session_start();
session_destroy();
?>
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">

<!-- Bootstrap CSS -->


<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css"
integrity="sha384-/Y6pD6FV/Vv2HJnA6t+vslU6fwYXjCFtcEpHbNJ0lyAFsXTsjBbfaDjzA
LeQsN6M" crossorigin="anonymous">
<style >
.btn-outline-light:hover {
color: #0076d4;
background-color: #f8f9fa;
border-color: #f8f9fa;
}
</style>
</head>
<body style="background: -webkit-linear-gradient(left, #3931af,
#00c6ff);color:white;padding-top:100px;text-align:center;">
<h3>You have logged out.</h3><br><br>
<a href="index.php" class="btn btn-outline-light">Back to Home Page</a>
<!-- Optional JavaScript -->
<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-
KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN"
crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js"
integrity="sha384-b/U6ypiBEHpOf/4+1nzFpr53nxSS+GLCkfwBdFNTxtclqqenISfwAzpKa
MNFNmj4" crossorigin="anonymous"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js"
integrity="sha384-
h0AbiXch4ZDo7tp9hKZ4TsHbi047NrKGLO3SEJAg45jXxnGIfYzk4Si90RDIqNm1"
crossorigin="anonymous"></script>
</body>
</html>

80
4.4: Limitations and Bibliography

A Hospital Management System (HMS) is designed to streamline various operations within a


hospital, including patient care, staff management, scheduling, billing, and inventory.
However, while these systems offer a wide range of benefits, they also have several
limitations:
1. High Initial Cost
 Expense: Implementing an HMS often involves a significant upfront cost for software
acquisition, hardware infrastructure, and training. This can be challenging for small or
medium-sized hospitals with limited budgets.

81
2. Complexity in Implementation
 Integration Issues: Many hospitals already use legacy systems, and integrating new
HMS solutions with existing software can be complex. Data migration and
synchronization can be difficult, leading to potential errors or delays.
 Customization: The system may need to be tailored to the specific needs of a hospital,
which can increase the complexity of setup and maintenance.
3. Data Security Risks
 Sensitive Information: HMS often stores sensitive patient data, such as medical
histories and personal information. If the system is not properly secured, it could be
vulnerable to hacking, data breaches, or unauthorized access.
 Compliance: Hospitals need to ensure that their system complies with health data
protection regulations (e.g., HIPAA in the U.S.). Compliance can be challenging,
especially for smaller institutions or hospitals in developing countries.
4. User Training and Adoption
 Learning Curve: Hospital staff may find it difficult to adapt to the new system,
especially if they are not technologically inclined. Proper training and ongoing
support are necessary, which can be time-consuming and expensive.
 Resistance to Change: Some employees, particularly those used to traditional
methods, may resist the implementation of a new system, leading to inefficiencies and
reduced adoption.
5. Technical Issues
 System Downtime: Like any software, an HMS can experience technical issues such
as system crashes, downtime, or bugs. This could lead to disruptions in patient care or
administrative tasks.
 Dependence on Technology: The system may be vulnerable to internet or power
outages, which could cause interruptions in hospital operations.

Bibliography

The above content I have taken from:

 Facebook for developers: https://developers.Doctor Appointment system.com/docs/


 W3Schools: https://www.w3schools.com/html/
 MDN Web Docs: https://developer.mozilla.org/en-US/docs/Web/CSS
 Youtube: www.youtube.com
 Google: www.google.com

82

You might also like