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

$kode	= $_POST[kode];
$text	= "SELECT * FROM retur_pb WHERE kode_rb= '$kode' GROUP BY kode_rb";
$sql 	= mysql_query($text);
$row	= mysql_num_rows($sql);
if ($row>0){
while ($r=mysql_fetch_array($sql)){
	$data['tgl']			= $r[tanggal];
	$data['nomorfk']	= $r[nomor_fk];
	$data['tanggalfk']	= $r[tanggal_fk];
	echo json_encode($data);
}
}else{
	$data['tgl']			= '';
	$data['nomorfk']	= '';
	$data['tanggalfk']	= '';
	echo json_encode($data);
}
?>