1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<h2>Acara Kegiatan Himatif</h2>
<table class="table table-bordered">
<thead>
<tr>
<th>no</th>
<th>Nama</th>
<th>Waktu</th>
<th>tempat</th>
<th>deskripsi</th>
<th>Foto</th>
<th>aksi</th>
</tr>
</thead>
<tbody>
<?php $nomor=1; ?>
<?php $ambil=$koneksi->query("SELECT * FROM kegiatan"); ?>
<?php while($pecah = $ambil->fetch_assoc()){ ?>
<tr>
<td><?php echo $nomor; ?></td>
<td><?php echo $pecah['nama_kegiatan']; ?></td>
<td><?php echo $pecah['waktu_kegiatan']; ?></td>
<td><?php echo $pecah['tempat_kegiatan']; ?></td>
<td><?php echo $pecah['deskripsi_kegiatan']; ?></td>
<td>
<img src="../foto_kegiatan/<?php echo $pecah['foto_kegiatan']; ?>" width="100">
</td>
<td>
<a href="index.php?halaman=hapuskegiatan&id=<?php echo $pecah['kegiatan_id']; ?>" class="btn-danger btn">Hapus</a>
<a href="index.php?halaman=ubahkegiatan&id=<?php echo $pecah['kegiatan_id']; ?>" class="btn btn-warning">Ubah</a>
</td>
</tr>
<?php $nomor++; ?>
<?php } ?>
</tbody>
</table>
<a href="index.php?halaman=tambahkegiatan" class="btn btn-primary">Tambah Kegiatan</a>