I am trying to post a td from a form.
this is my td...
<td class="product'.$id.' " name="qnty" value="'.$value.'">'.$value.'</td>
since that has no input field, how i will post that value?
Because i am trying to post it like this, and it is not working.
if(isset($_POST['submit_post'])){
$fabric=$_POST['fabric'];
$size=$_POST['size'];
$qnty=$_POST['qnty'];
$ins_sql = "INSERT INTO orders (fabric,size,product_quantity)
VALUES ('$fabric', '$size' , '$qnty')";
if ($conn->query($ins_sql) === TRUE) {
echo "New record created successfully";
} else {
echo "Error: " ;
}
$conn->close();
}
The rest of the posts are from dropdowns and they are working fine. Why this is not working?
Error: Undefined index: qnty