<?php
  session_start();
  if(empty($_SESSION['branch']) || $_SESSION['branch'] == ''){
    header("Location: index.php");
    die();
  }
    require_once 'system/conn.php';

$delete=$conn->query("DELETE FROM `emp_details` WHERE `e_id`='".$_GET['id']."'");
if($delete){
     $delete=$conn->query("DELETE FROM `emp_branch_salary` WHERE `emp_id`='".$_GET['id']."'");
     echo "<script>window.location.assign('view-all-emp.php')</script>";
  }
?>