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

$kode	= $_POST['kode'];
$exp	= explode("-",$kode);
$koderj	= $exp[0];
$kodest	= $exp[1];

$sql = mysql_query("SELECT * FROM retur_pj WHERE kode_rj= '$koderj' AND kode_st='$kodest' ORDER BY kode_rj");
$row	= mysql_num_rows($sql);
if ($row>0){
	$input = "DELETE FROM retur_pj WHERE kode_rj= '$koderj' AND kode_st='$kodest'";
	mysql_query($input);	
}else{
	echo "Maaf, tidak ada";
}
?>