"deleting multiple rows using checkboxes, php and mysql" Answer’s


in html page do it like this

<input name="checkbox[<?php echo $row['id']?>]"

and in the back end do like this

foreach ($delete as $id => $val) {
        $query="DELETE FROM documents WHERE id = '".$id."'";
        $result= mysqli_query($con, $query) or die("Invalid query");
Wednesday, March 31, 2021
answered 10 Months ago
Only authorized users can answer the question. Please sign in first, or register a free account.
Not the answer you're looking for? Browse other questions tagged :