Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php include_once('atas.php'); ?>
- <!-- Content Wrapper. Contains page content -->
- <div class="content-wrapper">
- <!-- Content Header (Page header) -->
- <section class="content-header">
- <div class="container-fluid">
- <div class="row mb-2">
- <div class="col-sm-6">
- <h1>Pengaturan Kelas</h1>
- </div>
- <div class="col-sm-6">
- <ol class="breadcrumb float-sm-right">
- <li class="breadcrumb-item"><a href="#">Master</a></li>
- <li class="breadcrumb-item"><a href="?m=kelas">Kelas</a></li>
- <li class="breadcrumb-item active">View</li>
- </ol>
- </div>
- </div>
- </div><!-- /.container-fluid -->
- </section>
- <!-- Main content -->
- <section class="content">
- <!-- Default box -->
- <div class="card">
- <div class="card-header">
- <h3 class="card-title">Kelas</h3>
- <div class="card-tools">
- <button type="button" class="btn btn-tool" data-card-widget="maximize" title="Maximize">
- <i class="fas fa-expand"></i>
- </button>
- <button type="button" class="btn btn-tool" data-card-widget="collapse" title="Collapse">
- <i class="fas fa-minus"></i>
- </button>
- <button type="button" class="btn btn-tool" data-card-widget="remove" title="Remove">
- <i class="fas fa-times"></i>
- </button>
- </div>
- </div>
- <div class="card-body">
- <div class="card-header">
- <h3 class="card-title">Data Kelas</h3>
- <div class="card-tools">
- <div class="input-group input-group-sm" style="width: 150px;">
- <input type="text" name="table_search" class="form-control float-right" placeholder="Search">
- <div class="input-group-append">
- <button type="submit" class="btn btn-default">
- <i class="fas fa-search"></i>
- </button>
- </div>
- </div>
- </div>
- </div>
- <!-- /.card-header -->
- <div class="card-body table-responsive p-0">
- <table class="table table-hover text-nowrap">
- <thead>
- <tr>
- <th>No</th>
- <th>Nama Kelas</th>
- <th>Jumlah Siswa</th>
- <th>Aksi</th>
- </tr>
- </thead>
- <tbody>
- <?php
- include_once('../koneksi.php');
- $sql = "SELECT * FROM grades ORDER BY id ASC";
- $result = $koneksi->query($sql);
- if($result->num_rows > 0) {
- $no=1;
- while($b = $result->fetch_assoc()) {
- echo "<tr>";
- echo "<td>$no</td>";
- echo "<td>" . $b['grade'] . "</td>";
- echo "<td>" . $b['amount'] . "</td>";
- echo '<td><a href="edit.php?id=' . $b['id'] . '">Edit</a> | <a href="delete.php?id=' . $b['id'] . '" onclick="return confirm(\'Yakin akan dihapus?\nSeluruh data siswa dikelas ini akan ikut terhapus.\')">Hapus</a></td>';
- echo "</tr>";
- $no++;
- }
- } else {
- echo "<tr><td colspan=4>Data Kosong</td></tr>";
- }
- ?>
- </tbody>
- </table>
- </div>
- <!-- /.card-body -->
- </div>
- <!-- /.card-body -->
- <!-- <div class="card-footer">
- Footer
- </div> -->
- <!-- /.card-footer-->
- </div>
- <!-- /.card -->
- </section>
- <!-- /.content -->
- </div>
- <!-- /.content-wrapper -->
- <?php include_once('bawah.php'); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement