<?php
function hitungJumlah($koneksi, $tabel) {
    $sql = "SELECT COUNT(*) as total FROM $tabel";
    $query = mysqli_query($koneksi, $sql);
    $data = mysqli_fetch_assoc($query);
    return $data['total'];
}
?>