edit

parent 59ead1f0
......@@ -2,6 +2,8 @@
session_start();
include_once 'functions/fungsi.php';
include_once 'connection/koneksi.php';
?>
<!DOCTYPE html>
<html>
......@@ -91,8 +93,8 @@ include_once 'connection/koneksi.php';
<?php
$per_hal = 8;
$jumlah_record = mysqli_query("SELECT * from menu");
$jum = mysqli_num_rows($conn,$jumlah_record);
$jumlah_record = mysqli_query($conn, "SELECT * from menu");
$jum = mysqli_num_rows($jumlah_record);
$halaman = ceil($jum / $per_hal);
$page = (isset($_GET['page'])) ? (int) $_GET['page'] : 1;
$start = ($page - 1) * $per_hal;
......@@ -112,8 +114,8 @@ $start = ($page - 1) * $per_hal;
<div class="col-lg-12">
<?php
$query = mysqli_query($conn,"SELECT * FROM menu limit $start, $per_hal");
$result_set = $database->query($query);
$query = "SELECT * FROM menu limit $start, $per_hal";
$result_set = $conn->query($query);
while ($row = $result_set->fetch_assoc()) {
?>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment