0% found this document useful (0 votes)
41 views3 pages

$pasienbaru

This document contains the code for a website interface for a hospital patient registration system. The interface includes a navbar with login/logout links at the top, an introduction section, and forms to input new patient information and search/view existing patient records stored in a database table. It links to external Bootstrap and jQuery libraries for styling and interactivity.

Uploaded by

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

$pasienbaru

This document contains the code for a website interface for a hospital patient registration system. The interface includes a navbar with login/logout links at the top, an introduction section, and forms to input new patient information and search/view existing patient records stored in a database table. It links to external Bootstrap and jQuery libraries for styling and interactivity.

Uploaded by

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

1 <!

doctype html>
2 <html lang="en">
3 <head>
4 <!-- Required meta tags -->
5 <meta charset="utf-8">
6 <meta name="viewport" content="width=device-width, initial-scale=1,
shrink-to-fit=no">
7
8 <!-- Bootstrap CSS -->
9 <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">
10 <link rel="stylesheet" href="css/style.css">
11 <link rel="icon" href="img/portfolio/rawat jalan.png"/>
12 <title>APLIKASI RS ESA MEDIKA</title>
13 </head>
14 <body>
15
16 <!-- jumbotron -->
17 <div class="jumbotron text-center">
18 <right><nav class="nav fixed-top-end">
19 <a class="nav-item nav-link btn btn-outline-primary" href="akunuser.php?logoutSubmit=1"
class="logout">Logout</a>
20 </nav></right>
21 <img src="img/index1.png" class="img-circle">
22 <h2> RUMAH SAKIT ESA MEDIKA</h2>
23 mutu pelayanan adalah keselamatan
24 <nav class="nav nav-pills nav-justified">
25 <a class="nav-item nav-link btn btn-outline-primary" href="PELAYANAN MEDIK
ADMIN.php">Pelayanan</a>
26 <a class="nav-item nav-link btn btn-outline-primary" href="pencarian
status.php">Status Pasien</a>
27 </nav>
28 </div>
29 <!-- akhir jumbotron -->
30 <!-- form -->
31 <section class="about" id="about">
32 <div class="container">
33 <div class="row">
34 <div class="col-sm-12">
35 <h2 class="text-center">Form Pasien RAWAT INAP</h2>
36 <hr>
37 </div>
38 </div>
39 <div class="row">
40 <div class="col-sm-6">
41 <form method="post" action="simpan.php">
42 <input type="hidden" value="<?php echo $pasienbaru['id']; ?>">
43 <div class="form-group">
44 <table border="0" align="center">
45 <tr>
46 <td colspan="3" align="center"></td>
47 </tr>
48 <tr>
49 <td>Nama</td>
50 <td>:</td>
51 <td><input type="text" name="Nama" id="Nama" required /></td>
52 </tr>
53 <tr>
54 <td>TTL</td>
55 <td>:</td>
56 <td><input type="date" name="TTL" id="TTL" /></td>
57 </tr>
58 <tr>
59 <td>Alamat</td>
60 <td>:</td>
61 <td><input type="text" name="Alamat" id="Alamat" /></td>
62 </tr>
63 <tr>
64 <td>NoHP</td>
65 <td>:</td>
66 <td><input type="text" name="NoHP" id="NoHP" /></td>
67 </tr>
68 <td><input type="submit" name="simpan">
69 <input type="reset" value="Reset"/></td>
70
71 </table>
72 </div>
73 </form>
74 </div>
75 <div class="col-sm-6">
76 <?php
77 // koneksi ke database
78 $conn = mysqli_connect("localhost","root","","dtpasien");
79
80
81 // cek dulu tombol submit
82 if (isset($_POST['submit'])) {
83 $cari=$_POST['cari'];
84 $result = mysqli_query($conn, "SELECT * FROM pasienbaru WHERE Nama LIKE '$cari%'");
85 } else{
86 $result = mysqli_query($conn, "SELECT * FROM pasienbaru");
87 }
88
89 // ambil data dari table daftar pasien/query daftar pasien
90
91 // ambil data dari object result
92
93 ?>
94 <!DOCTYPE html>
95 <tr>
96 <td>
97 <td>Pencarian Pasien</td>
98 <form action="" method="post">
99 <input type="text" name="cari"
100 placeholder="input Nama"
101 autocomplete="off">
102 <button type="submit" name="submit"/>cari</button>
103 </form>
104 </td>
105 </tr>
106 <h1>daftar pasien</h1>
107 <table border="1" cellpadding="10" cellspacing="0">
108
109
110 <tr>
111 <th>NO.</th>
112 <th>aksi</th>
113 <th>Nama</th>
114 <th>TTL</th>
115 <th>Alamat</th>
116 <th>NoHP</th>
117 </tr>
118 <?php $i = 1; ?>
119 <?php while ($row = mysqli_fetch_assoc($result) ) : ?>
120 <tr>
121 <td><?= $i; ?></td>
122 <td>
123 <a href="edit.php?id=<?php echo $row['id'] ?>">edit</a> |
124 <a href="hapus6.php?id=<?php echo $row['id'] ?>">delete</a>
125 <td><?= $row["Nama"]; ?></td>
126 <td><?= $row["TTL"]; ?></td>
127 <td><?= $row["Alamat"]; ?></td>
128 <td><?= $row["NoHP"]; ?></td>
129 </td>
130
131 </tr>
132 <?php $i++; ?>
133 <?php endwhile; ?>
134 </table>
135
136 </div>
137 </div>
138 </div>
139 </section>
140 <!-- akhir about -->
141
142 <!-- footer -->
143 <footer>
144 <div class="container">
145 <div class="row">
146 <div class="col-sm-12 text-center">
147 <p>&copy 2019 | built by. <a
href="https://www.esaunggul.ac.id/esa-medhika-clinic/?lang=en"></a></p>
148 </div>
149 </div>
150 </div>
151 </footer>
152 <!-- akhir footer -->
153
154 <!-- Optional JavaScript -->
155 <!-- jQuery first, then Popper.js, then Bootstrap JS -->
156 <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"
integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo"
crossorigin="anonymous"></script>
157 <script
src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js"
integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1"
crossorigin="anonymous"></script>
158 <script
src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js"
integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM"
crossorigin="anonymous"></script>
159 </body>
160 </html>

You might also like