<?php 
include "config.php";
$product = $_POST['pro'];
if ($product != '')
{
$sql = "select * from productdetail where productcode ='$product' && status!='deleted' ";
$conn=mysqli_query($connect,$sql);
while($row=mysqli_fetch_array($conn))
{
    $state = $row['price'];
}

echo $state;
}
else 
{
    echo "";
}
?>