Professional Documents
Culture Documents
on
E-HOSPITAL SERVICES
Submitted By:
MANIKKAME HRITIK SANJAY
MANTRI PIYUSH DHANRAJ
GADEKAR NARENDRA WAMANRAO
Affiliated to
Certificate
Seat No. ZC19097 ) submitted in partial fulfillment of the requirements for the award of
– 431606 during the academic year 2022-23, is a bonafide record of work carried out
Examinar-1 Examinar-2
Declaration
We hereby declare that project entitled "E-HOSPITAL SERVICES" has been
Computer Science & IT, Nanded and Submitted to Swami Ramanand Teerth
Pathak for the award of degree of Bachelor of Science (Computer Science). This
report comprises only our original work and has not been submitted for award of any
other degree to any university. Due acknowledgement has been made in the text to all
Date:6/4/2023
Place:Nanded
Acknowledgement
It gives us an immense pleasure and satisfaction to present this project report on “E-
HOSPITAL SERVICE”, which is the result of unwavering support, expert guidance and
focused direction of our guide Mr. Vishal Marotirao Pathak to whom we express our deep
sense of gratitude and humble thanks, for her valuable guidance throughout the presentation
work.
The success of this Project has throughout depended upon an exact blend of hard work
and unending co-operation and guidance, extended to us by the supervisors at our college.
Furthermore, we are indebted to our HOD Dr. Mrs. Kanchan A. Nandedkar and Principal
Prof. Shirish L. Kotgire whose constant encouragement and motivation inspired us to do
my best.
Last but not the least we sincerely thank to our colleagues, the staff and all others who
directly or indirectly helped us and made numerous suggestions which have surely improved
the quality of our work.
1. ABSTRACT 1
2. INTRODUCTION 2
3. REQUIREMENTS 2
4. PROJECT DIAGRAMS 3
5. SOURCE CODE 5
6. OUTPUT 78
7. CONCLUSION 87
8. REFERENCES 88
LIST OF FIGURES
PAGE
FIGURE NO.
The purpose of the project entitled as “E-HOSPITAL SERVICE” is to computerize the Front Office
Management of Hospital to develop software which is user friendly simple, fast, and cost – effective. It deals
with the collection of patient’s information, diagnosis details, etc. Traditionally, it was done manually. The
main function of the system is register and store patient details and doctor details and retrieve these details as
and when required, and also to manipulate these details meaningfully System input contains patient details,
diagnosis details, while system output is to get these details on to the screen. E-Hospital Service system can
be entered using a username and password. It is accessible either by an administrator or receptionist. Only
they can add data into the database. The data can be retrieved easily. The data are well protected for personal
use and makes the data processing very fast.
1.2.PURPOSE :
1.3. SCOPE :
1) Information about Patients is done by just writing the Patients name, age and gender. Whenever the
Patient comes up his information is stored freshly.
2) Bills are generated by recording price for each facility provided to Patient on a separate sheet and at last
they all are summed up.
3) Diagnosis information to patients is generally recorded on the document, which contains Patient
information. It is destroyed after some time period to decrease the paper load in the office.
4) Immunization records of children are maintained in pre-formatted sheets, which are kept in a file.
5) Information about various diseases is not kept as any document.
Doctors themselves do this job by remembering various medicines..
1
E-HOSPITAL SERVICES
2. INTRODUCTION :
The project E-Hospital Service system includes registration of patients, storing their details into the system,
and also computerized billing in the pharmacy, and labs. User can search availability of a doctor and the
details of a patient using the name. The Hospital Management System can be entered using a username and
password. It is accessible either by an administrator or receptionist. Only they can add data into the database.
The data can be retrieved easily. The interface is very user-friendly. The data are well protected for personal
use and makes the data processing very fast. Hospital Management System is powerful, flexible, and easy to
use and is designed and developed to deliver real conceivable benefits to hospitals. Hospital Management
System is designed for multispeciality hospitals, to cover a wide range of hospital administration and
management processes. It is an integrated end- to-end Hospital Management System that provides relevant
information across the hospital to support effective decision making for patient care, hospital administration
and critical financial accounting, in a seamless flow. E-Hospital Management System is a software product
suite designed to improve the quality and management of hospital management in the areas of clinical
process analysis and activity-based costing. Hospital Management System enables you to develop your
organization and improve its effectiveness and quality of work. Managing the key processes efficiently is
critical to the success of the hospital helps you manage your processes.
3. REQUIREMENTS :
2
E-HOSPITAL SERVICES
4. PROJECT DIAGRAMS :
4.1.DATA FLOW DIAGRAM :
Figure 2.1
3
E-HOSPITAL SERVICES
4.2. E-R DIAGRAM :
Figure 2.2
4
E-HOSPITAL SERVICES
5. SOURCE CODE :
5.1.HOME PAGE :
<html>
<head>
<title>HMS</title>
<link rel="shortcut icon" type="image/x-icon" href="images/favicon.png" />
<link rel="stylesheet" type="text/css" href="style1.css">
<link href="https://fonts.googleapis.com/css?family=IBM+Plex+Sans&display=swap" rel="stylesheet">
<!-- <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css"
integrity="sha384-HSMxcRTRxnN+Bdg0JdbxYKrThecOKuH5zCYotlSAcp1+c8xmyTe9GYg1l9a69psu"
crossorigin="anonymous"> -->
<style >
.form-control {
border-radius: 0.75rem;
}
</style>
<script>
var check = function() {
if (document.getElementById('password').value ==
document.getElementById('cpassword').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);
};
function checklen()
{
var pass1 = document.getElementById("password");
if(pass1.value.length<6){
alert("Password must be at least 6 characters long. Try again!");
5
E-HOSPITAL SERVICES
return false;
}
}
</script>
</head>
<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>
6
E-HOSPITAL SERVICES
</div>
<div class="col-md-9 register-right" style="margin-top: 40px;left: 80px;">
<ul class="nav nav-tabs nav-justified" id="myTab" role="tablist" style="width: 40%;">
<li class="nav-item">
<a class="nav-link active" id="home-tab" data-toggle="tab" href="#home" role="tab"
aria-controls="home" aria-selected="true">Patient</a>
</li>
<li class="nav-item">
<a class="nav-link" id="profile-tab" data-toggle="tab" href="#profile" role="tab" aria-
controls="profile" aria-selected="false">Doctor</a>
</li>
<li class="nav-item">
<a class="nav-link" id="profile-tab" data-toggle="tab" href="#admin" role="tab" aria-
controls="admin" aria-selected="false">Receptionist</a>
</li>
</ul>
<div class="tab-content" id="myTabContent">
<div class="tab-pane fade show active" id="home" role="tabpanel" aria-
labelledby="home-tab">
<h3 class="register-heading">Register as Patient</h3>
<form method="post" action="func2.php">
<div class="row register-form">
<div class="col-md-6">
<div class="form-group">
<input type="text" class="form-control" placeholder="First Name *"
name="fname" onkeydown="return alphaOnly(event);" required/>
</div>
<div class="form-group">
<input type="email" class="form-control" placeholder="Your Email *"
name="email" />
</div>
<div class="form-group">
<input type="password" class="form-control" placeholder="Password *"
id="password" name="password" onkeyup='check();' required/>
</div>
<div class="form-group">
<div class="maxl">
<label class="radio inline">
<input type="radio" name="gender" value="Male" checked>
<span> Male </span>
</label>
<label class="radio inline">
<input type="radio" name="gender" value="Female">
<span>Female </span>
</label>
</div>
<a href="index1.php">Already have an account?</a>
</div>
7
E-HOSPITAL SERVICES
</div>
<div class="col-md-6">
<div class="form-group">
<input type="text" class="form-control" placeholder="Last Name *"
name="lname" onkeydown="return alphaOnly(event);" required/>
</div>
<div class="form-group">
<input type="tel" minlength="10" maxlength="10" name="contact" class="form-
control" placeholder="Your Phone *" />
</div>
<div class="form-group">
<input type="password" class="form-control" id="cpassword"
placeholder="Confirm Password *" name="cpassword" onkeyup='check();' required/><span
id='message'></span>
</div>
<input type="submit" class="btnRegister" name="patsub1" onclick="return
checklen();" value="Register"/>
</div>
</div>
</form>
</div>
8
E-HOSPITAL SERVICES
</div>
<div class="col-md-6">
<div class="form-group">
<input type="password" class="form-control" placeholder="Password *"
name="password2" required/>
</div>
</div>
</div>
</div>
</body>
9
E-HOSPITAL SERVICES
</head>
<style type="text/css">
#inputbtn:hover{cursor:pointer;}
.card{
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%;
}
10
E-HOSPITAL SERVICES
</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">
<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>
11
E-HOSPITAL SERVICES
</div>
12
E-HOSPITAL SERVICES
<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>
</div>
</div>
13
E-HOSPITAL SERVICES
5.3. ABOUT US PAGE :
<html lang="en"><head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Services</title>
<style>
.bg-skin {
background: #0062cc;
}
.nav>li>a:hover, .nav>li>a:focus {
text-decoration: none;
background-color: #251f1f00;
/* color: blue; */
}
.btn-skin {
14
E-HOSPITAL SERVICES
background-color: #0062cc;
border-color: #0062cc;
}
.box h4 {
font-size: 24px;
color: white;
font-family: 'IBM Plex Sans', sans-serif;
}
.service-desc h5 {
margin-bottom: 10px;
color: white;
font-family: 'IBM Plex Sans', sans-serif;
}
.fa-stethoscope:before {
color: white;
}
.fa-h-square:before {
color: white;
}
.fa-wheelchair:before {
color: white;
}
.fa-filter:before {
color: white;
}
.fa-plus-square:before {
color: white;
}
.fa-user-md:before {
15
E-HOSPITAL SERVICES
color: white;
background: #00ffff2b;
}
.fa-check:before {
background: #084dbe;
}
.fa-list-alt:before {
background: #005cd0;
}
.fa-hospital-o:before {
background: #0eacf0de
}
.fa-heartbeat:before {
color: white;
}
footer .widget h5 {
font-size: 20px;
margin-bottom: 10px;
text-transform: uppercase;
color: white;
}
.intro-content {
/*background: url(../img/dummy/bg1.jpg) no-repeat top center;*/
background:-webkit-linear-gradient(left, #3931af, #00c6ff);
padding: 200px 0 60px;
}
</style>
16
E-HOSPITAL SERVICES
</head>
<body style="">
<div class="container navigation" style="background: -webkit-linear-gradient(left, #3931af,
#00c6ff);width: 98.85vw;height: 70px;padding-top: 10px;">
</div>
<div id="wrapper">
<div class="col-lg-6">
<div class="wow fadeInDown animated" data-wow-offset="0" data-wow-delay="0.1s"
style="visibility: visible; animation-delay: 0.1s; animation-name: fadeInDown;">
<h2 style="font-family: 'IBM Plex Sans', sans-serif;color: white">GLOBAL HOSPITALS</h2>
</div>
<div class="wow fadeInUp animated" data-wow-offset="0" data-wow-delay="0.1s"
style="visibility: visible; animation-delay: 0.1s; animation-name: fadeInUp;">
<h4 class="h-light" style="font-family: 'IBM Plex Sans', sans-serif;color: #efe1e1">Provide best
quality healthcare for you</h4>
</div>
<div class="well well-trans" style="background:#ffffff00;color: white">
<div class="wow fadeInRight animated" data-wow-delay="0.1s" style="visibility: visible;
animation-delay: 0.1s; animation-name: fadeInRight;">
<ul class="lead-list">
<li><span class="fa fa-check-square-o fa-2x icon-success"></span> <span
class="list"><strong>Affordable monthly premium packages</strong><br>Lorem ipsum dolor sit amet, in
verterem persecuti vix, sit te meis</span></li>
<li><span class="fa fa-check-square-o fa-2x icon-success"></span> <span
class="list"><strong>Choose your favourite services</strong><br>Lorem ipsum dolor sit amet, in verterem
persecuti vix, sit te meis</span></li>
<li><span class="fa fa-check-square-o fa-2x icon-success"></span> <span
class="list"><strong>Only use friendly environment</strong><br>Lorem ipsum dolor sit amet, in verterem
persecuti vix, sit te meis</span></li>
</ul>
<p class="text-right wow bounceIn animated" data-wow-delay="0.4s" style="visibility: visible;
animation-delay: 0.4s; animation-name: bounceIn;">
<a href="#" class="btn btn-skin btn-lg" style="background:white;color:#006ccf">Learn more <i
class="fa fa-angle-right"></i></a>
</p>
</div>
</div>
</div>
18
E-HOSPITAL SERVICES
<div class="col-lg-6">
<div class="wow fadeInUp animated" data-wow-duration="2s" data-wow-delay="0.2s"
style="visibility: visible; animation-duration: 2s; animation-delay: 0.2s; animation-name: fadeInUp;">
<img src="img/dummy/img-1.png" class="img-responsive" alt="">
</div>
</div>
</div>
</div>
</div>
</section>
<div class="container">
<div class="row">
<div class="col-sm-3 col-md-3">
<div class="wow fadeInUp animated" data-wow-delay="0.3s" style="visibility: visible; animation-
delay: 0.3s; animation-name: fadeInUp;">
<div class="box text-center">
19
E-HOSPITAL SERVICES
<div class="wow fadeInUp animated" data-wow-delay="0.5s" style="visibility: visible; animation-
delay: 0.5s; animation-name: fadeInUp;">
<div class="box text-center">
20
E-HOSPITAL SERVICES
</p>
</div>
</div>
</div>
</div>
</div>
</section>
<section id="service" class="home-section nopadding paddingtop-60" style="background: -webkit-linear-
gradient(left, #3931af, #00c6ff);color: white">
<div class="container">
<div class="row">
<div class="col-sm-6 col-md-6">
<div class="wow fadeInLeft animated" data-wow-delay="0.2s" style="visibility: visible; animation-
delay: 0.2s; animation-name: fadeInLeft;">
<img src="img/dummy/img-6.png" class="img-responsive" alt="">
</div>
</div>
<div class="col-sm-3 col-md-3">
<div class="wow fadeInRight animated" data-wow-delay="0.1s" style="visibility: visible;
animation-delay: 0.1s; animation-name: fadeInRight;">
<div class="service-box">
<div class="service-icon">
<span class="fa fa-stethoscope fa-3x" style="color:#0062cc"></span>
</div>
<div class="service-desc">
<h5 class="h-light">Medical checkup</h5>
<p>Vestibulum tincidunt enim in pharetra malesuada.</p>
</div>
</div>
</div>
21
E-HOSPITAL SERVICES
<div class="wow fadeInRight animated" data-wow-delay="0.2s" style="visibility: visible;
animation-delay: 0.2s; animation-name: fadeInRight;">
<div class="service-box">
<div class="service-icon">
<span class="fa fa-wheelchair fa-3x" style="color:#0062cc"></span>
</div>
<div class="service-desc">
<h5 class="h-light">Nursing Services</h5>
<p>Vestibulum tincidunt enim in pharetra malesuada.</p>
</div>
</div>
</div>
<div class="wow fadeInRight animated" data-wow-delay="0.3s" style="visibility: visible;
animation-delay: 0.3s; animation-name: fadeInRight;">
<div class="service-box">
<div class="service-icon">
<span class="fa fa-plus-square fa-3x" style="color:#0062cc"></span>
</div>
<div class="service-desc">
<h5 class="h-light">Pharmacy</h5>
<p>Vestibulum tincidunt enim in pharetra malesuada.</p>
</div>
</div>
</div>
</div>
<div class="col-sm-3 col-md-3">
<div class="wow fadeInRight animated" data-wow-delay="0.1s" style="visibility: visible;
animation-delay: 0.1s; animation-name: fadeInRight;">
<div class="service-box">
<div class="service-icon">
<span class="fa fa-h-square fa-3x" style="color:#0062cc"></span>
</div>
<div class="service-desc">
<h5 class="h-light">Gyn Care</h5>
22
E-HOSPITAL SERVICES
<p>Vestibulum tincidunt enim in pharetra malesuada.</p>
</div>
</div>
</div>
<div class="wow fadeInRight animated" data-wow-delay="0.2s" style="visibility: visible;
animation-delay: 0.2s; animation-name: fadeInRight;">
<div class="service-box">
<div class="service-icon">
<span class="fa fa-filter fa-3x" style="color:#0062cc"></span>
</div>
<div class="service-desc">
<h5 class="h-light">Neurology</h5>
<p>Vestibulum tincidunt enim in pharetra malesuada.</p>
</div>
</div>
</div>
<div class="wow fadeInRight animated" data-wow-delay="0.3s" style="visibility: visible;
animation-delay: 0.3s; animation-name: fadeInRight;">
<div class="service-box">
<div class="service-icon">
<span class="fa fa-heartbeat fa-3x"></span>
</div>
<div class="service-desc">
<h5 class="h-light">Sleep Center</h5>
<p>Vestibulum tincidunt enim in pharetra malesuada.</p>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
<footer style="background: -webkit-linear-gradient(left, #3931af, #00c6ff);color: #e4d6d6">
23
E-HOSPITAL SERVICES
<div class="container">
<div class="row">
<div class="col-sm-6 col-md-4">
<div class="wow fadeInDown animated" data-wow-delay="0.1s" style="visibility: visible;
animation-delay: 0.1s; animation-name: fadeInDown;">
<div class="widget">
<h5>About Global Hospitals</h5>
<p>
Lorem ipsum dolor sit amet, ne nam purto nihil impetus, an facilisi accommodare sea
</p>
</div>
</div>
<div class="wow fadeInDown animated" data-wow-delay="0.1s" style="visibility: visible;
animation-delay: 0.1s; animation-name: fadeInDown;">
<div class="widget">
<h5>Information</h5>
<ul>
<li><a style="color: #e4d6d6" href="#">Home</a></li>
<li><a style="color: #e4d6d6" href="#">Laboratory</a></li>
<li><a style="color: #e4d6d6" href="#">Medical treatment</a></li>
<li><a style="color: #e4d6d6" href="#">Terms & conditions</a></li>
</ul>
</div>
</div>
</div>
<div class="col-sm-6 col-md-4">
<div class="wow fadeInDown animated" data-wow-delay="0.1s" style="visibility: visible;
animation-delay: 0.1s; animation-name: fadeInDown;">
<div class="widget">
<h5>Global Hospitals</h5>
<p>
Nam leo lorem, tincidunt id risus ut, ornare tincidunt naqunc sit amet.
</p>
24
E-HOSPITAL SERVICES
<ul>
<li>
25
E-HOSPITAL SERVICES
<div class="widget">
<h5>Follow us</h5>
<ul class="company-social">
<li class="social-facebook"><a href="#"><i class="fa fa-facebook"></i></a></li>
<li class="social-twitter"><a href="#"><i class="fa fa-twitter"></i></a></li>
<li class="social-google"><a href="#"><i class="fa fa-google-plus"></i></a></li>
<li class="social-vimeo"><a href="#"><i class="fa fa-vimeo-square"></i></a></li>
<li class="social-dribble"><a href="#"><i class="fa fa-dribbble"></i></a></li>
</ul>
</div>
</div>
</div>
</div>
</div>
</footer>
</div>
26
E-HOSPITAL SERVICES
<html><head>
<title>Contact Us</title>
<link rel="shortcut icon" type="image/x-icon" href="images/favicon.png">
<link href="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css"
rel="stylesheet" id="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" type="text/css" href="contact.css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/js/bootstrap.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script>
function alphaOnly(event) {
var key = event.keyCode;
return ((key >= 65 && key <= 90) || key == 8 || key == 32);
};
</script>
<style>
body{
background: -webkit-linear-gradient(left, #3931af, #00c6ff);
}
.contact-form {
background: #f8f9fa;
border-top-left-radius: 10% 50%;
border-bottom-left-radius: 10% 50%;
border-top-right-radius: 10% 50%;
border-bottom-right-radius: 10% 50%; }
</style>
</head>
<body>
<nav class="navbar navbar-expand-lg navbar-dark fixed-top" id="mainNav">
<div class="container">
</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>
<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 contact-form" style="font-family: 'IBM Plex Sans', sans-serif;">
<div class="contact-image">
<img src="https://image.ibb.co/kUagtU/rocket_contact.png"
alt="rocket_contact">
</div>
<form method="post" action="contact.php">
<h3>Drop Us a Message</h3>
<div class="row">
<div class="col-md-6">
<div class="form-group">
<input type="text" name="txtName" class="form-control"
placeholder="Your Name *" value="" onkeydown="return alphaOnly(event);" required="">
</div>
<div class="form-group">
<input type="email" name="txtEmail" class="form-control"
placeholder="Your Email *" value="" required="">
</div>
<div class="form-group">
<input type="tel" name="txtPhone" class="form-control"
placeholder="Your Phone Number *" value="" minlength="10" maxlength="10" required="">
</div>
<div class="form-group">
<input type="submit" name="btnSubmit" class="btnContact"
value="Send Message">
</div>
</div>
<div class="col-md-6">
<div class="form-group">
<textarea name="txtMsg" class="form-control" placeholder="Your
Message *" style="width: 100%; height: 150px;" required=""></textarea>
</div>
</div>
</div>
</form>
</div>
</body></html>
28
E-HOSPITAL SERVICES
<?php
$con=mysqli_connect("localhost","root","","myhmsdb");
if(isset($_POST['btnSubmit']))
{
$name = $_POST['txtName'];
$email = $_POST['txtEmail'];
$contact = $_POST['txtPhone'];
$message = $_POST['txtMsg'];
if($result)
{
echo '<script type="text/javascript">';
echo 'alert("Message sent successfully!");';
echo 'window.location.href = "contact.html";';
echo '</script>';
}
}
body{
background: -webkit-linear-gradient(left, #3931af, #00c6ff);
}
html {
overflow-y: scroll;
}
.contact-form{
background: #fff;
margin-top: 10%;
margin-bottom: 5%;
width: 70%;
}
.contact-form .form-control{
border-radius:1rem;
29
E-HOSPITAL SERVICES
}
.contact-image{
text-align: center;
}
.contact-image img{
border-radius: 6rem;
width: 11%;
margin-top: -4%;
transform: rotate(29deg);
}
.contact-form form{
padding: 14%;
}
.contact-form form .row{
margin-bottom: -7%;
}
.contact-form h3{
margin-bottom: 8%;
margin-top: -13%;
text-align: center;
color: #495057;
}
.contact-form .btnContact {
width: 50%;
border: none;
border-radius: 1rem;
padding: 1.5%;
background: #0062cc;
font-weight: 600;
color: #fff;
cursor: pointer;
}
.btnContactSubmit
{
width: 50%;
border-radius: 1rem;
padding: 1.5%;
color: #fff;
background-color: #0062cc;
border: none;
cursor: pointer;
}
.btnContact{
margin-left: 70%;
}
30
E-HOSPITAL SERVICES
5.5. PATIENT “LOGGED IN” PANEL :
- Here you’ll see dashboard,appointment details,etc.
<!DOCTYPE html>
<?php
include('func.php');
include('newfunc.php');
$con=mysqli_connect("localhost","root","","myhmsdb");
$pid = $_SESSION['pid'];
$username = $_SESSION['username'];
$email = $_SESSION['email'];
$fname = $_SESSION['fname'];
$gender = $_SESSION['gender'];
$lname = $_SESSION['lname'];
$contact = $_SESSION['contact'];
if(isset($_POST['app-submit']))
{
$pid = $_SESSION['pid'];
$username = $_SESSION['username'];
$email = $_SESSION['email'];
$fname = $_SESSION['fname'];
$lname = $_SESSION['lname'];
$gender = $_SESSION['gender'];
$contact = $_SESSION['contact'];
$doctor=$_POST['doctor'];
$email=$_SESSION['email'];
# $fees=$_POST['fees'];
$docFees=$_POST['docFees'];
$appdate=$_POST['appdate'];
$apptime=$_POST['apptime'];
$cur_date = date("Y-m-d");
date_default_timezone_set('Asia/Kolkata');
$cur_time = date("H:i:s");
$apptime1 = strtotime($apptime);
$appdate1 = strtotime($appdate);
if(date("Y-m-d",$appdate1)>=$cur_date){
if((date("Y-m-d",$appdate1)==$cur_date and date("H:i:s",$apptime1)>$cur_time) or
date("Y-m-d",$appdate1)>$cur_date) {
$check_query = mysqli_query($con,"select apptime from appointmenttb where
doctor='$doctor' and appdate='$appdate' and apptime='$apptime'");
31
E-HOSPITAL SERVICES
if(mysqli_num_rows($check_query)==0){
$query=mysqli_query($con,"insert into
appointmenttb(pid,fname,lname,gender,email,contact,doctor,docFees,appdate,apptime,userStat
us,doctorStatus)
values($pid,'$fname','$lname','$gender','$email','$contact','$doctor','$docFees','$appdate
','$apptime','1','1')");
if($query)
{
echo "<script>alert('Your appointment successfully booked');</script>";
}
else{
echo "<script>alert('Unable to process your request. Please try
again!');</script>";
}
}
else{
echo "<script>alert('We are sorry to inform that the doctor is not available in
this time or date. Please choose different time or date!');</script>";
}
}
else{
echo "<script>alert('Select a time or date in the future!');</script>";
}
}
else{
echo "<script>alert('Select a time or date in the future!');</script>";
}
if(isset($_GET['cancel']))
{
$query=mysqli_query($con,"update appointmenttb set userStatus='0' where ID =
'".$_GET['ID']."'");
if($query)
{
echo "<script>alert('Your appointment successfully cancelled');</script>";
}
}
function generate_bill(){
$con=mysqli_connect("localhost","root","","myhmsdb");
$pid = $_SESSION['pid'];
$output='';
32
E-HOSPITAL SERVICES
$query=mysqli_query($con,"select
p.pid,p.ID,p.fname,p.lname,p.doctor,p.appdate,p.apptime,p.disease,p.allergy,p.prescription
,a.docFees from prestb p inner join appointmenttb a on p.ID=a.ID and p.pid = '$pid' and
p.ID = '".$_GET['ID']."'");
while($row = mysqli_fetch_array($query)){
$output .= '
<label> Patient ID : </label>'.$row["pid"].'<br/><br/>
<label> Appointment ID : </label>'.$row["ID"].'<br/><br/>
<label> Patient Name : </label>'.$row["fname"].' '.$row["lname"].'<br/><br/>
<label> Doctor Name : </label>'.$row["doctor"].'<br/><br/>
<label> Appointment Date : </label>'.$row["appdate"].'<br/><br/>
<label> Appointment Time : </label>'.$row["apptime"].'<br/><br/>
<label> Disease : </label>'.$row["disease"].'<br/><br/>
<label> Allergies : </label>'.$row["allergy"].'<br/><br/>
<label> Prescription : </label>'.$row["prescription"].'<br/><br/>
<label> Fees Paid : </label>'.$row["docFees"].'<br/>
';
return $output;
}
if(isset($_GET["generate_bill"])){
require_once("TCPDF/tcpdf.php");
$obj_pdf = new TCPDF('P',PDF_UNIT,PDF_PAGE_FORMAT,true,'UTF-8',false);
$obj_pdf -> SetCreator(PDF_CREATOR);
$obj_pdf -> SetTitle("Generate Bill");
$obj_pdf -> SetHeaderData('','',PDF_HEADER_TITLE,PDF_HEADER_STRING);
$obj_pdf -> SetHeaderFont(Array(PDF_FONT_NAME_MAIN,'',PDF_FONT_SIZE_MAIN));
$obj_pdf -> SetFooterFont(Array(PDF_FONT_NAME_MAIN,'',PDF_FONT_SIZE_MAIN));
$obj_pdf -> SetDefaultMonospacedFont('helvetica');
$obj_pdf -> SetFooterMargin(PDF_MARGIN_FOOTER);
$obj_pdf -> SetMargins(PDF_MARGIN_LEFT,'5',PDF_MARGIN_RIGHT);
$obj_pdf -> SetPrintHeader(false);
$obj_pdf -> SetPrintFooter(false);
$obj_pdf -> SetAutoPageBreak(TRUE, 10);
$obj_pdf -> SetFont('helvetica','',12);
$obj_pdf -> AddPage();
$content = '';
$content .= '
<br/>
<h2 align ="center"> Global Hospitals</h2></br>
<h3 align ="center"> Bill</h3>
33
E-HOSPITAL SERVICES
';
$content .= generate_bill();
$obj_pdf -> writeHTML($content);
ob_end_clean();
$obj_pdf -> Output("bill.pdf",'I');
function get_specs(){
$con=mysqli_connect("localhost","root","","myhmsdb");
$query=mysqli_query($con,"select username,spec from doctb");
$docarray = array();
while($row =mysqli_fetch_assoc($query))
{
$docarray[] = $row;
}
return json_encode($docarray);
}
?>
<html lang="en">
<head>
<link rel="stylesheet"
href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
34
E-HOSPITAL SERVICES
integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T"
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 >
.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;
}
.btn-primary{
background-color: #3c50c1;
border-color: #3c50c1;
}
</style>
</style>
<body style="padding-top:50px;">
</div><br>
</div>
<div class="col-md-8" style="margin-top: 3%;">
<div class="tab-content" id="nav-tabContent" style="width: 950px;">
36
E-HOSPITAL SERVICES
<p class="cl-effect-1">
<a href="#app-hist" onclick="clickDiv('#list-pat-list')">
View Appointment History
</a>
</p>
</div>
</div>
</div>
</div>
<p class="cl-effect-1">
<a href="#list-pres" onclick="clickDiv('#list-pres-list')">
View Prescription List
</a>
</p>
</div>
</div>
</div>
</div>
</div>
37
E-HOSPITAL SERVICES
<!-- <?php
$con=mysqli_connect("localhost","root","","myhmsdb");
$query=mysqli_query($con,"select username,spec from doctb");
$docarray = array();
while($row =mysqli_fetch_assoc($query))
{
$docarray[] = $row;
}
echo json_encode($docarray);
?> -->
<div class="col-md-4">
<label for="spec">Specialization:</label>
</div>
<div class="col-md-8">
<select name="spec" class="form-control" id="spec">
<option value="" disabled selected>Select
Specialization</option>
<?php
display_specs();
?>
</select>
</div>
<br><br>
<script>
document.getElementById('spec').onchange = function foo() {
let spec = this.value;
console.log(spec)
let docs = [...document.getElementById('doctor').options];
</script>
<script>
document.getElementById('doctor').onchange = function updateFees(e) {
var selection =
document.querySelector(`[value=${this.value}]`).getAttribute('data-value');
document.getElementById('docFees').value = selection;
};
</script>
</select>
</div>
<br><br> -->
<!-- <script>
document.getElementById("spec").onchange = function
updateSpecs(event) {
var selected = document.querySelector(`[data-
value=${this.value}]`).getAttribute("value");
console.log(selected);
var options =
document.getElementById("doctor1").querySelectorAll("option");
if (category == selected) {
currentOption.style.display = "block";
} else {
currentOption.style.display = "none";
}
39
E-HOSPITAL SERVICES
}
}
</script> -->
<!-- <script>
let data =
</div><br><br>
<div class="col-md-4">
<input type="submit" name="app-submit" value="Create new entry"
class="btn btn-primary" id="inputbtn">
</div>
40
E-HOSPITAL SERVICES
<div class="col-md-8"></div>
</div>
</form>
</div>
</div>
</div><br>
</div>
$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;
$query = "select
ID,doctor,docFees,appdate,apptime,userStatus,doctorStatus from appointmenttb where fname
='$fname' and lname='$lname';";
$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['doctor'];?></td>
<td><?php echo $row['docFees'];?></td>
<td><?php echo $row['appdate'];?></td>
<td><?php echo $row['apptime'];?></td>
<td>
<?php if(($row['userStatus']==1) && ($row['doctorStatus']==1))
{
echo "Active";
}
41
E-HOSPITAL SERVICES
<td>
<?php if(($row['userStatus']==1) && ($row['doctorStatus']==1))
{ ?>
echo "Cancelled";
} ?>
</td>
</tr>
<?php } ?>
</tbody>
</table>
<br>
</div>
<th scope="col">Prescriptions</th>
<th scope="col">Bill Payment</th>
</tr>
</thead>
<tbody>
<?php
$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;
$query = "select
doctor,ID,appdate,apptime,disease,allergy,prescription from prestb where pid='$pid';";
$result = mysqli_query($con,$query);
if(!$result){
echo mysqli_error($con);
}
</tr>
<?php }
?>
43
E-HOSPITAL SERVICES
</tbody>
</table>
<br>
</div>
</body>
</html>
44
E-HOSPITAL SERVICES
5.6. DOCTOR,S “LOGGED IN” PANEL :
<!DOCTYPE html>
<?php
include('func1.php');
$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>
<link rel="stylesheet"
href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T"
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><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">
47
E-HOSPITAL SERVICES
</div>
</div>
</div>
</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";
}
<td>
<?php if(($row['userStatus']==1) && ($row['doctorStatus']==1))
{ ?>
49
E-HOSPITAL SERVICES
echo "Cancelled";
} ?>
</td>
<td>
echo "-";
} ?>
</td>
</tr></a>
<?php } ?>
</tbody>
</table>
<br>
</div>
$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);
}
</tr>
<?php }
?>
</tbody>
</table>
</div>
$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;
#$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>
<td><?php echo $row['apptime'];?></td>
</tr>
<?php } ?>
</tbody>
</table>
<br>
</div>
52
E-HOSPITAL SERVICES
53
E-HOSPITAL SERVICES
5.7. RECEPTIONIST’S ‘LOGGED IN” PANEL :
<!DOCTYPE html>
<?php
$con=mysqli_connect("localhost","root","","myhmsdb");
include('newfunc.php');
if(isset($_POST['docsub']))
{
$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>
54
E-HOSPITAL SERVICES
<link rel="stylesheet"
href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T"
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{
55
E-HOSPITAL SERVICES
max-width:20% !important;
}
.list-group-item.active {
z-index: 2;
color: #fff;
background-color: #342ac1;
border-color: #007bff;
}
.text-primary {
color: #342ac1!important;
}
#cpass {
display: -webkit-box;
}
#list-app{
font-size:15px;
}
.btn-primary{
background-color: #3c50c1;
border-color: #3c50c1;
}
</style>
</div><br>
</div>
<div class="col-md-8" style="margin-top: 3%;">
<div class="tab-content" id="nav-tabContent" style="width: 950px;">
<p class="cl-effect-1">
<a href="#app-hist" onclick="clickDiv('#list-pat-list')">
View Patients
</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>
58
E-HOSPITAL SERVICES
<p class="cl-effect-1">
<a href="#app-hist" onclick="clickDiv('#list-adoc-list')">Add
Doctors</a>
 |
<a href="#app-hist" onclick="clickDiv('#list-ddoc-list')">
Delete Doctors
</a>
</p>
</div>
</div>
</div>
</div>
</div>
</div>
<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">
59
E-HOSPITAL SERVICES
<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
$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="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>
60
E-HOSPITAL SERVICES
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="col-md-8">
61
E-HOSPITAL SERVICES
<div class="row">
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>
62
E-HOSPITAL SERVICES
</tr>";
}
?>
</tbody>
</table>
<br>
</div>
</div>
</div>
<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>
$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;
63
E-HOSPITAL SERVICES
</div>
<input type="submit" name="docsub1" value="Delete Doctor" class="btn btn-
primary" onclick="confirm('do you really want to delete?')">
</form>
</div>
65
E-HOSPITAL SERVICES
<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>
$con=mysqli_connect("localhost","root","","myhmsdb");
global $con;
#$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>
66
E-HOSPITAL SERVICES
</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+GLCkfwBdFNTxtclqqenISfwAzpKaMNFNmj4"
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>
<!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">
<!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">
68
E-HOSPITAL SERVICES
integrity="sha384-b/U6ypiBEHpOf/4+1nzFpr53nxSS+GLCkfwBdFNTxtclqqenISfwAzpKaMNFNmj4"
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>
<!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">
69
E-HOSPITAL SERVICES
5.9. SQL CODE :
--
-- Database: `myhmsdb`
--
-- --------------------------------------------------------
--
-- Table structure for table `admintb`
--
--
-- Dumping data for table `admintb`
--
-- --------------------------------------------------------
--
-- Table structure for table `appointmenttb`
--
70
E-HOSPITAL SERVICES
--
-- Dumping data for table `appointmenttb`
--
INSERT INTO `appointmenttb` (`pid`, `ID`, `fname`, `lname`, `gender`, `email`, `contact`,
`doctor`, `docFees`, `appdate`, `apptime`, `userStatus`, `doctorStatus`) VALUES
(4, 1, 'Kishan', 'Lal', 'Male', 'kishansmart0@gmail.com', '8838489464', 'Ganesh', 550,
'2020-02-14', '10:00:00', 1, 0),
(4, 2, 'Kishan', 'Lal', 'Male', 'kishansmart0@gmail.com', '8838489464', 'Dinesh', 700,
'2020-02-28', '10:00:00', 0, 1),
(4, 3, 'Kishan', 'Lal', 'Male', 'kishansmart0@gmail.com', '8838489464', 'Amit', 1000,
'2020-02-19', '03:00:00', 0, 1),
(11, 4, 'Shraddha', 'Kapoor', 'Female', 'shraddha@gmail.com', '9768946252', 'ashok', 500,
'2020-02-29', '20:00:00', 1, 1),
(4, 5, 'Kishan', 'Lal', 'Male', 'kishansmart0@gmail.com', '8838489464', 'Dinesh', 700,
'2020-02-28', '12:00:00', 1, 1),
(4, 6, 'Kishan', 'Lal', 'Male', 'kishansmart0@gmail.com', '8838489464', 'Ganesh', 550,
'2020-02-26', '15:00:00', 0, 1),
(2, 8, 'Alia', 'Bhatt', 'Female', 'alia@gmail.com', '8976897689', 'Ganesh', 550, '2020-03-
21', '10:00:00', 1, 1),
(5, 9, 'Gautam', 'Shankararam', 'Male', 'gautam@gmail.com', '9070897653', 'Ganesh', 550,
'2020-03-19', '20:00:00', 1, 0),
(4, 10, 'Kishan', 'Lal', 'Male', 'kishansmart0@gmail.com', '8838489464', 'Ganesh', 550,
'0000-00-00', '14:00:00', 1, 0),
(4, 11, 'Kishan', 'Lal', 'Male', 'kishansmart0@gmail.com', '8838489464', 'Dinesh', 700,
'2020-03-27', '15:00:00', 1, 1),
(9, 12, 'William', 'Blake', 'Male', 'william@gmail.com', '8683619153', 'Kumar', 800,
'2020-03-26', '12:00:00', 1, 1),
(9, 13, 'William', 'Blake', 'Male', 'william@gmail.com', '8683619153', 'Tiwary', 450,
'2020-03-26', '14:00:00', 1, 1);
-- --------------------------------------------------------
71
E-HOSPITAL SERVICES
--
-- Table structure for table `contact`
--
--
-- Dumping data for table `contact`
--
-- --------------------------------------------------------
--
-- Table structure for table `doctb`
--
--
-- Dumping data for table `doctb`
--
-- --------------------------------------------------------
--
-- Table structure for table `patreg`
--
--
-- Dumping data for table `patreg`
--
INSERT INTO `patreg` (`pid`, `fname`, `lname`, `gender`, `email`, `contact`, `password`,
`cpassword`) VALUES
(1, 'Ram', 'Kumar', 'Male', 'ram@gmail.com', '9876543210', 'ram123', 'ram123'),
(2, 'Alia', 'Bhatt', 'Female', 'alia@gmail.com', '8976897689', 'alia123', 'alia123'),
(3, 'Shahrukh', 'khan', 'Male', 'shahrukh@gmail.com', '8976898463', 'shahrukh123',
'shahrukh123'),
(4, 'Kishan', 'Lal', 'Male', 'kishansmart0@gmail.com', '8838489464', 'kishan123',
'kishan123'),
(5, 'Gautam', 'Shankararam', 'Male', 'gautam@gmail.com', '9070897653', 'gautam123',
'gautam123'),
(6, 'Sushant', 'Singh', 'Male', 'sushant@gmail.com', '9059986865', 'sushant123',
'sushant123'),
(7, 'Nancy', 'Deborah', 'Female', 'nancy@gmail.com', '9128972454', 'nancy123',
'nancy123'),
(8, 'Kenny', 'Sebastian', 'Male', 'kenny@gmail.com', '9809879868', 'kenny123',
'kenny123'),
(9, 'William', 'Blake', 'Male', 'william@gmail.com', '8683619153', 'william123',
'william123'),
(10, 'Peter', 'Norvig', 'Male', 'peter@gmail.com', '9609362815', 'peter123', 'peter123'),
(11, 'Shraddha', 'Kapoor', 'Female', 'shraddha@gmail.com', '9768946252', 'shraddha123',
'shraddha123');
-- --------------------------------------------------------
--
73
E-HOSPITAL SERVICES
--
-- Dumping data for table `prestb`
--
INSERT INTO `prestb` (`doctor`, `pid`, `ID`, `fname`, `lname`, `appdate`, `apptime`,
`disease`, `allergy`, `prescription`) VALUES
('Dinesh', 4, 11, 'Kishan', 'Lal', '2020-03-27', '15:00:00', 'Cough', 'Nothing', 'Just
take a teaspoon of Benadryl every night'),
('Ganesh', 2, 8, 'Alia', 'Bhatt', '2020-03-21', '10:00:00', 'Severe Fever', 'Nothing',
'Take bed rest'),
('Kumar', 9, 12, 'William', 'Blake', '2020-03-26', '12:00:00', 'Sever fever', 'nothing',
'Paracetamol -> 1 every morning and night'),
('Tiwary', 9, 13, 'William', 'Blake', '2020-03-26', '14:00:00', 'Cough', 'Skin dryness',
'Intake fruits with more water content');
--
-- Indexes for dumped tables
--
--
-- Indexes for table `appointmenttb`
--
ALTER TABLE `appointmenttb`
ADD PRIMARY KEY (`ID`);
--
-- Indexes for table `patreg`
--
ALTER TABLE `patreg`
ADD PRIMARY KEY (`pid`);
--
-- AUTO_INCREMENT for dumped tables
--
74
E-HOSPITAL SERVICES
--
-- AUTO_INCREMENT for table `appointmenttb`
--
ALTER TABLE `appointmenttb`
MODIFY `ID` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=14;
--
-- AUTO_INCREMENT for table `patreg`
--
ALTER TABLE `patreg`
MODIFY `pid` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=12;
COMMIT;
<?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">
<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>
75
E-HOSPITAL SERVICES
<?php
session_start();
$con=mysqli_connect("localhost","root","","myhmsdb");
if(isset($_POST['search_submit'])){
$contact=$_POST['contact'];
$docname = $_SESSION['dname'];
$query="select * from appointmenttb where contact='$contact' and doctor='$docname';";
$result=mysqli_query($con,$query);
echo '<!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">
<th>Appointment Date</th>
<th>Appointment Time</th>
</tr>
</thead>
<tbody>
';
while($row=mysqli_fetch_array($result)){
$fname=$row['fname'];
$lname=$row['lname'];
$email=$row['email'];
$contact=$row['contact'];
$appdate=$row['appdate'];
$apptime=$row['apptime'];
echo '<tr>
<td>'.$fname.'</td>
<td>'.$lname.'</td>
<td>'.$email.'</td>
<td>'.$contact.'</td>
<td>'.$appdate.'</td>
<td>'.$apptime.'</td>
</tr>';
}
echo '</tbody></table></div>
<div><a href="doctor-panel.php" class="btn btn-light">Go Back</a></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+GLCkfwBdFNTxtclqqenISfwAzpKaMNFNmj4"
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>';
}
?>
77
E-HOSPITAL SERVICES
6. OUTPUT :
HOME PAGE :
78
E-HOSPITAL SERVICES
PATIENT APPOINTMENT PAGE :
79
E-HOSPITAL SERVICES
DOCTOR’S LOGIN :
LOGIN PAGE:
80
E-HOSPITAL SERVICES
81
E-HOSPITAL SERVICES
ADMIN’S LOGIN :
82
E-HOSPITAL SERVICES
83
E-HOSPITAL SERVICES
84
E-HOSPITAL SERVICES
85
E-HOSPITAL SERVICES
86
E-HOSPITAL SERVICES
7. CONCLUSION :
Since we are entering details of the patients electronically in the” EHospital Service”, data will be secured.
Using this website we can retrieve patient’s history with a single click.Thus processing information will be
faster.
It guarantees accurate maintenance of Patient details. It easily reduces the book keeping task and thus
reduces the human effort and increases accuracy speed.
87
E-HOSPITAL SERVICES
8. REFERENCES :
1. PHP MySQL Website Programming: Problem - Design – Solution byChris Lea, Mike Buzzard, Dilip
Thomas , Jessey White-Cinis
2. Beginning PHP5, Apache, and MySQL Web Development (Programmer to Programmer) by Elizabeth
Naramore
88