<?php
$del = mysqli_query($con,"DELETE FROM tb_materi WHERE id_materi='$_GET[ID]' ") or die(mysqli_error($con));
if ($del) {	

	echo "
	<script type='text/javascript'>
	setTimeout(function () {
	swal({
	title: 'SUCCESS',
	text:  'Data Deleted Successfully !!',
	type: 'success',
	timer: 3000,
	showConfirmButton: true
	});     
	},10);  
	window.setTimeout(function(){ 
	window.location.replace('?page=materi');
	} ,3000);   
	</script>";
}

 ?>