Delete Data From Database Code in php
<?php
include_once 'dbconnect.php' ;
$id= $_GET['/'];
$sql = "delete from vritant_tbl where id ='{$id}'";
$reslut_set = mysqli_query($conn,$sql);
$count = mysqli_affected_rows($conn);
if($count) {
?>
<script>
window.alert("Student Information Deleted");
window.location.href="show.php";
</script>
<?php
}else{
?>
<script>
window.alert("Not Deleted");
window.location.href="show.php";
</script>
<?php
}
?>
0 Comments