Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="utf-8">
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <meta name="description" content="">
- <meta name="author" content="">
- <title>SB Admin - Bootstrap Admin Template</title>
- <!-- Bootstrap Core CSS -->
- <link href="css/bootstrap.min.css" rel="stylesheet">
- <!-- Custom CSS -->
- <link href="css/sb-admin.css" rel="stylesheet">
- <!-- Morris Charts CSS -->
- <link href="css/plugins/morris.css" rel="stylesheet">
- <!-- Custom Fonts -->
- <link href="font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css">
- <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
- <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
- <!--[if lt IE 9]>
- <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
- <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
- <![endif]-->
- <!-- DataTables -->
- <link rel="stylesheet" href="css/dataTables.bootstrap.css">
- <?php
- require_once('core/init.php');
- $result = tampilUser();
- //print_r($result);
- ?>
- </head>
- <body>
- <div id="wrapper">
- <?php
- require_once('template/nav.php');
- ?>
- <div id="page-wrapper">
- <div class="container-fluid">
- <!-- Page Heading -->
- <div class="row">
- <div class="col-lg-12">
- <h1 class="page-header">
- Data User
- </h1>
- <ol class="breadcrumb">
- <li>
- <i class="fa fa-dashboard"></i> <a href="index.html">Dashboard</a>
- </li>
- <li class="active">
- <i class="fa fa-table"></i> Tables
- </li>
- </ol>
- </div>
- </div>
- <!-- /.row -->
- <div class="container-fluid">
- <div class="row">
- <div class="col-lg-12">
- <a href="add_user.php" class="btn btn-primary">Tambah Data</a>
- <hr>
- <div class="table-responsive">
- <table class="table table-bordered table-hover table-striped" id="example1">
- <thead>
- <tr>
- <th>#</th>
- <th>Username</th>
- <th>Password</th>
- <th>Status</th>
- <th>Action</th>
- </tr>
- </thead>
- <tbody>
- <?php
- $no=0;
- $no++;
- while ($row = mysqli_fetch_assoc($result)) {
- ?>
- <tr>
- <td><?php echo $no++; ?></td>
- <td><?php echo $row['username']; ?></td>
- <td><?php echo $row['password']; ?></td>
- <td><?php echo $row['status']; ?></td>
- <td><a href="edit_user.php?id=<?php echo $row['id']; ?>" class="btn btn-sm btn-success">Edit</a>
- <a href="delete_user.php?id=<?php echo $row['id']; ?>" class="btn btn-sm btn-danger">Delete</a>
- </td>
- </tr>
- <?php } //end while ?>
- </tbody>
- </table>
- </div>
- </div>
- </div>
- </div>
- <!-- /.row -->
- </div>
- <!-- /.container-fluid -->
- </div>
- <!-- /#page-wrapper -->
- </div>
- <!-- /#wrapper -->
- <?php
- require_once('template/header.php');
- ?>
- <script src="js/jquery-1.11.1.min.js"></script>
- <script src="js/bootstrap.min.js"></script>
- <script src="js/jquery.dataTables.min.js"></script>
- <script src="js/dataTables.bootstrap.js"></script>
- <script type="text/javascript">
- $(function() {
- $('#example1').dataTable();
- });
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment