<?php
	session_start();

	if(!isset($_SESSION['tulsilogin']))
	{
		header('Location: index.php');
		return;
	}

	include("connect.php");
	
	$abmid =(int)mysqli_real_escape_string($conn,$_GET['id']);
	$umid =(int)mysqli_real_escape_string($conn,$_GET['umid']);

	
	
	$query="delete from res_agentbranch_master where abmid =$abmid ";
	$result= mysqli_query($conn, $query) or die("Error");

	

	$_SESSION['msg'] = "Record deleted successfully";
	header("Location: agentdetail.php?id=$umid");
	

?>