I try to delete
my data in \"admin\" database, but the delete button does not function.
This is my top part
$sql = "SELECT * FROM blacklist";
$result = $link->query($sql);
$count=mysqli_num_rows($result);
if ($result->num_rows > 0) {
while($row = $result->fetch_assoc())
{
echo "";
echo "";
echo " " . "ID: " . $row["id"]." ";
echo "" . " Dial Target: " . $row["dial_target"]." ";
echo "" . " Destination: " . $row["pozn"]." ";
echo "" . " Date: " . $row["block_date"] . " ";
echo "" . "" . "" . "" . " ";
echo "";
echo "
";
echo "";
}
}
else
{
echo "0 results";
}
if(isset($_POST['Delete']))
{
for($i=0;$i<$count;$i++)
{
$del_id = $checkbox[$i];
$del = "DELETE FROM blacklist WHERE Delete='$del_id'";
$result = $link->query($del);
}
if($result)
{
echo "";
}
}