<?php 
include "../config.php";
$ticket = $_POST['ticket'];
//echo $customer;
if ($ticket != '')
{
$sql = "select *,(select customerdetails.name from customerdetails where customerdetails.code = ticket.customer )as cusname,(select productdetail.productname from productdetail where productdetail.productcode = ticket.product )as proname from ticket where ticket = '$ticket' && status !='deleted'";
//echo $sql;
$conn=mysqli_query($connect,$sql);
while($row=mysqli_fetch_array($conn))
{
       $product = $row['product'];
       
         
}
echo $product;
}
else
{
 echo "";
}

?>
