<?php
session_start();
ob_start();
 include "../config/config.php"; 
 include "../config/function.php"; 
 
 print_r($_REQUEST);
 $private_key=get_privatekey();
 $request_from_server=$_SERVER['HTTP_REFERER'];
$this_server=$_SERVER['HTTP_HOST'];
if($request_from_server!=''){
	check_access_url($request_from_server,$this_server);
}

// echo $_SESSION['login_status'];echo "<br>";
// echo $_SESSION['private_key'];echo "<br>";
// echo $_SESSION['admin_name'];echo "<br>";

if($_SESSION['login_status']!='YES' || $_SESSION['private_key']!=$private_key || $_SESSION['private_key']=='' || $_SESSION['admin_name']=='')
{
    echo "Blank";
	header("Location:../AppLogin");
	exit();
}
else
{
$member_user_id=strtoupper(trim($_POST['member_user_id']));
$member_name=strtoupper(trim($_POST['member_name']));
$plot_id=trim($_POST['plotCode']);

$Update="Update tbl_plot_master set booking_status=1,booking_customer='$member_name' where plot_id=$plot_id";
mysqli_query($connection,$Update);
echo "Plot Booking Successfully";

}
header("location:../SetCustomerPlot?msg=$msg");
exit();
?>