
<?php
include 'koneksi.php'; // koneksi ke database

$ktp = $_POST['ktp'];

$query = mysqli_query($koneksi, "SELECT * FROM anggota WHERE ktp = '$ktp'");
if (mysqli_num_rows($query) > 0) {
    echo 'true';
} else {
    echo 'false';
}
?>