<?php
session_start();
include('../config/database.php');
$repoArray = explode(',',$_POST['questionAllId']);
$questionAllId = $_POST['questionAllId'];	
if(!empty($questionAllId))
{					
	$sqlProduct = mysqli_query($cn,"delete from `tbl_sh` where `id` IN($questionAllId)");				
	if($sqlProduct)
	{		
		$arr    = array("status"=>1, 'successMsg'=>count($repoArray)." Record Deleted SuccessFully");		
		$_SESSION['successMsg'] = count($repoArray)." Record Deleted SuccessFully.";
		echo json_encode($arr);
	}
	else
	{
		$arr    = array("status"=>2, 'SuccessMsg'=>"Record Not Deleted Try Again.");		
		echo json_encode($arr);
	}
}
else
{
	$arr    = array("status"=>2, 'SuccessMsg'=>"Atleast select One Record.");		
	echo json_encode($arr);
}		
?>