I am trying to make a function that will delete a news entry and each entry will have a delete function attached to it. Here is the code I have for it:Here is the link that is added to each post:PHP Code:if($_GET['cmd'] == "delete") {
$sql = "DELETE FROM `news` WHERE id = '$id'";
$result = mysql_query($sql) or die ('Could not delete the post! <br />' .mysql_error());
echo 'The article has been deleted! <a href="edit_news.php">Return to Edit Page</a>';
}
The code looks like it should work to me, but when I click on the link, I get a blank page with no code on it and it does not delete the news post. I appreciate any help :)HTML Code:<a href="edit_news.php?cmd=delete&id='.$id.'">Delete</a>

