<?php 
include '../koneksi.php';
$id = $_POST['id'];              
$data = mysqli_query($koneksi, "select * from brg_dft where id='$id'");
$d = mysqli_fetch_assoc($data);

$id2 = $d['id'];
$kode = $d['kode'];
$nama = $d['nama'];
$klp = $d['klp'];

$returnArr = [$id2,$kode,$nama,$klp];    
echo json_encode($returnArr);
?>