
<?php

session_start();
@ob_start();
include "../../config/koneksi.php";

$module=$_GET[module];
$act=$_GET[act];
 
// Input YM
if ($module=='cust' AND $act=='add'){
	$cust = mysql_result(mysql_query("select customername from customers where customerid = $_POST[cust]"),0);
	$sales = $_SESSION['nama'];
	mysql_query("INSERT INTO special(produk,customer,price,sales) VALUES('$_POST[produk]','$cust','$_POST[price]','$sales')");
	header('location:dataprice.php');

}


elseif ($module=='cust' AND $act=='delete'){
	mysql_query("delete from special  where id = $_GET[id]");
	header('location:dataprice.php');

}

?>
