<?php
session_start();
include 'dbc.php';

date_default_timezone_set("Asia/Karachi");
$today=date("Y-m-d");
$month = date("m",strtotime($today));
		$year = date("Y",strtotime($today));
		 $month_name = date("F", mktime(0, 0, 0, $month, 10));
		 $my=$month_name . " " . $year;
$userid=$_SESSION["userid"];

if($_POST['delete']) // from button name="delete"
	{
		$checkbox = $_POST['checkbox']; //from name="checkbox[]"
		$countCheck = count($_POST['checkbox']);
		
		for($i=0;$i<$countCheck;$i++)
		{
			$del_id  = $checkbox[$i];
			$userid=$_SESSION["userid"];
			$today=date("Y-m-d");
			
			

		$sql11 = "delete from familyno where id='$del_id'";
$conn->query($sql11);
			
	
	
	
			
		}
			if($result)
		{	
				header('Location: Open_All_Students.php');
			}
			else
			{
				header('Location: maindashboard.php');
			}
	}
  
	
	

// do the update and print out some info just to provide some visual feedback





?>
