<?php
include("include/config.inc.php");
if(!isset($_SESSION['s_activId']))
{
  $_SESSION['s_urlRedirectDir'] = $_SERVER['REQUEST_URI'];
  header("Location:checkLogin.php");
}
else
{
	$partyId   = isset($_REQUEST['partyId']) && $_REQUEST['partyId'] != '' ? $_REQUEST['partyId'] : 0;	 

    if($partyId > 0)
	{
	  $deleteEntry = "DELETE FROM client
                         WHERE  
					  partyId = ".$partyId; 
	   $insertClientRes = mysql_query($deleteEntry);
	    if(!$insertClientRes)
	    {
	  	  echo "Delete Fail";
	    }
	    else
	    {
	      header("Location:partyList.php");
	    }
	  
	}
	include("./bottom.php");
	$smarty->display("partyList.tpl");
}
?>