I'm trying to do a very simple task here, just delete an entry from one of my tables. I'm sure I'm just missing something obvious here but I can't for the life of me work out where.
Can anyone see where I'm going wrong here?
my code here
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$sql = "DELETE FROM `collectionsystemdocs` WHERE `collectionsystemdocs`.`name` = $id";
if (mysqli_query($conn, $sql)) {
echo 'Entry Deletion Successful<br>';
}
else {
echo 'Entry Deletion Unsuccessful<br>';
}
}