<?php
include "../../../../inc/conn.php";

$id         = $_POST['id'];

$sql = "select * from tb_siswa where id_siswa=".$id;
$result = mysqli_query($connect,$sql);

$response = "<div style='align:center;'>";
while( $row = mysqli_fetch_array($result) ){
?>
    <form action="hapussiswa" method="POST">
        
        <input type="hidden" name="id_siswa" value="<?php echo $id;?>">
        
        <table align="center">
            <tr><td align="center">
            <i style="font-size:50px;" class="fas fa-trash"></i>
            <br><br>
            Anda yakin akan menghapus data ini ?
            </td></tr>

            <tr><td align="center">
                <br>
                <button type="submit" class="btn btn-primary">Hapus</button>
                <button type="button" class="btn btn-default" data-dismiss="modal">Batal</button>
            </td></tr>
        </table>

    </form>
<?php
}
$response .= "</div";
echo $response;
exit;