<?PHP
	$leave_type = $_GET['leave_type'];
	include './conn.php';
	$sql1 = "DELETE FROM lms.leave_types WHERE leave_type = '".$leave_type."'";
	$sql2 = "DELETE FROM lms.leave_requests WHERE leave_type = '".$leave_type."'";
	$sql3 = "DELETE FROM lms.leave_statistics WHERE leave_type = '".$leave_type."'";
	echo 	"<script>
				alert(\"Do you really want to delete ".$leave_type."\");
			</script>";
	mysqli_query($conn,$sql1);
	mysqli_query($conn,$sql2);
	mysqli_query($conn,$sql3);
	echo "<script>window.location=\"delete_leave_type.php\";</script>";
	mysqli_close($conn);

?> 