<?
ob_start();
session_start();
if(isset($_SESSION['ses_name']))
{
$user=$_SESSION['ses_name'];
}else{
header("location:index.php");
}
$tyrenum_veh='';

include("include/config.php");
require_once "include/Database_functions.php";
$sqlObj=new sqlclass();

$tablename='cf_user_07';

		if(isset($_REQUEST['save'])){
			
			if(isset($_POST['emp_name'])){
			$emp_name=addslashes($_POST['emp_name']);
			}
			if(isset($_POST['username'])){
			$username=addslashes($_POST['username']);
			}
			if(isset($_POST['newpassword'])){
			$password1=addslashes($_POST['newpassword']);
			}
			
			if(isset($_POST['address'])){
			$address=addslashes($_POST['address']);
			}
			
			if(isset($_POST['phoneno'])){
			$phoneno=addslashes($_POST['phoneno']);
			}
							
			if(isset($_POST['master']))
			{
			$master=1;
			}
			else
			{
			$master=0;
			}
						
			if(isset($_POST['client']))
			{
			$client=1;
			}
			else
			{
			$client=0;
			}
			
			if(isset($_POST['vendor']))
			{
			$vendor=1;
			}
			else
			{
			$vendor=0;
			}
			
			if(isset($_POST['vehicle']))
			{
			$vehicle=1;
			}
			else
			{
			$vehicle=0;
			}
			
			if(isset($_POST['product']))
			{
			$product=1;
			}
			else
			{
			$product=0;
			}
			
			if(isset($_POST['kopra']))
			{
			$kopra=1;
			}
			else
			{
			$kopra=0;
			}
			
			if(isset($_POST['sku']))
			{
			$sku=1;
			}
			else
			{
			$sku=0;
			}
			
			
			if(isset($_POST['manageuser']))
			{
			$manageuser=1;
			}
			else
			{
			$manageuser=0;
			}
			
			if(isset($_POST['filmroll']))
			{
			$filmroll=1;
			}
			else
			{
			$filmroll=0;
			}
			
			
			
			
			if(isset($_POST['brand']))
			{
			$brand=1;
			}
			else
			{
			$brand=0;
			}
			
			if(isset($_POST['agmark']))
			{
			$agmark=1;
			}
			else
			{
			$agmark=0;
			}
			
			if(isset($_POST['openingbalance']))
			{
			$openingbalance=1;
			}
			else
			{
			$openingbalance=0;
			}
			
			
			if(isset($_POST['hr'])){
			$hr=1;
			}
			else
			{
			$hr=0;
			}
			
			if(isset($_POST['hr'])){
			$branch=1;
			}
			else
			{
			$branch=0;
			}
			
			if(isset($_POST['department'])){
			$department=1;
			}
			else
			{
			$department=0;
			}
			
			if(isset($_POST['designation'])){
			$designation=1;
			}
			else
			{
			$designation=0;
			}
			
			if(isset($_POST['employee'])){
			$employee=1;
			}
			else
			{
			$employee=0;
			}
			
			if(isset($_POST['timesheet'])){
			$timesheet=1;
			}
			else
			{
			$timesheet=0;
			}
			
			
			if(isset($_POST['leave'])){
			$leave=1;
			}
			else
			{
			$leave=0;
			}
			
			if(isset($_POST['payroll'])){
			$payroll=1;
			}
			else
			{
			$payroll=0;
			}
			
			if(isset($_POST['settings'])){
			$settings=1;
			}
			else
			{
			$settings=0;
			}
			
			if(isset($_POST['purchase'])){
			$purchase=1;
			}
			else
			{
			$purchase=0;
			}
			
			if(isset($_POST['oilpurchase'])){
			$oilpurchase=1;
			}
			else
			{
			$oilpurchase=0;
			}
			
			
			if(isset($_POST['koprapurchase'])){
			$koprapurchase=1;
			}
			else
			{
			$koprapurchase=0;
			}
			
			if(isset($_POST['purchasedashboard'])){
			$purchasedashboard=1;
			}
			else
			{
			$purchasedashboard=0;
			}		
			
			
			if(isset($_POST['inventory'])){
			$inventory=1;
			}
			else
			{
			$inventory=0;
			}
			
			if(isset($_POST['warehousestock'])){
			$warehousestock=1;
			}
			else
			{
			$warehousestock=0;
			}
			
			if(isset($_POST['skustock'])){
			$skustock=1;
			}
			else
			{
			$skustock=0;
			}
			
			if(isset($_POST['pinnakustock'])){
			$pinnakustock=1;
			}
			else
			{
			$pinnakustock=0;
			}
			
			if(isset($_POST['stationarystock'])){
			$stationarystock=1;
			}
			else
			{
			$stationarystock=0;
			}
						
			if(isset($_POST['packaging'])){
			$packaging=1;
			}
			else
			{
			$packaging=0;
			}
			
			if(isset($_POST['addpackage'])){
			$addpackage=1;
			}
			else
			{
			$addpackage=0;
			}
			
			if(isset($_POST['packagelist'])){
			$packagelist=1;
			}
			else
			{
			$packagelist=0;
			}
			
			if(isset($_POST['Agmarknostatus'])){
			$Agmarknostatus=1;
			}
			else
			{
			$Agmarknostatus=0;
			}
			
			if(isset($_POST['salebilling'])){
			$salebilling=1;
			}
			else
			{
			$salebilling=0;
			}
			
			
			
			if(isset($_POST['addsales'])){
			$addsales=1;
			}
			else
			{
			$addsales=0;
			}
			
			if(isset($_POST['saleslist'])){
			$saleslist=1;
			}
			else
			{
			$saleslist=0;
			}
			
							
			if(isset($_POST['tripsheetmgmt'])){
			$tripsheetmgmt=1;
			}
			else
			{
			$tripsheetmgmt=0;
			}
			
			if(isset($_POST['addtripsheet'])){
			$addtripsheet=1;
			}
			else
			{
			$addtripsheet=0;
			}
			
			if(isset($_POST['tripsheetpending'])){
			$tripsheetpending=1;
			}
			else
			{
			$tripsheetpending=0;
			}
			
			if(isset($_POST['tripsheetfinished'])){
			$tripsheetfinished=1;
			}
			else
			{
			$tripsheetfinished=0;
			}
			
			if(isset($_POST['vehiclemgmt'])){
			$vehiclemgmt=1;
			}
			else
			{
			$vehiclemgmt=0;
			}
			
			if(isset($_POST['vehiclenotification'])){
			$vehiclenotification=1;
			}
			else
			{
			$vehiclenotification=0;
			}
			
			if(isset($_POST['vehiclemilagemgmt'])){
			$vehiclemilagemgmt=1;
			}
			else
			{
			$vehiclemilagemgmt=0;
			}
			
			if(isset($_POST['accounts'])){
			$accounts=1;
			}
			else
			{
			$accounts=0;
			}
			
			if(isset($_POST['accountgroup'])){
			$accountgroup=1;
			}
			else
			{
			$accountgroup=0;
			}
			
			
			if(isset($_POST['ledgermgmt'])){
			$ledgermgmt=1;
			}
			else
			{
			$ledgermgmt=0;
			}
			
			if(isset($_POST['receipt'])){
			$receipt=1;
			}
			else
			{
			$receipt=0;
			}
			
			if(isset($_POST['voucher'])){
			$voucher=1;
			}
			else
			{
			$voucher=0;
			}
			
			if(isset($_POST['advance'])){
			$advance=1;
			}
			else
			{
			$advance=0;
			}
			
			if(isset($_POST['acpayable'])){
			$acpayable=1;
			}
			else
			{
			$acpayable=0;
			}
			
			if(isset($_POST['cashbook'])){
			$cashbook=1;
			}
			else
			{
			$cashbook=0;
			}
			
			if(isset($_POST['bankbook'])){
			$bankbook=1;
			}
			else
			{
			$bankbook=0;
			}
			
			if(isset($_POST['journal'])){
			$journal=1;
			}
			else
			{
			$journal=0;
			}
			
			if(isset($_POST['placs'])){
			$placs=1;
			}
			else
			{
			$placs=0;
			}
			
			
			
			//print_r($clientcode);
			//echo "<br/>";
			
			//echo $cnt = count($clientcode);	
			
						
						
			$sqlObj->tablename=$tablename;
			if($username!=''){
			/*$sqlObj->fieldname='(name,password,date,type,master_status,notif_status,trip_status,accounting_status,accpay_status,report_status,address,phone,status)';
			$sqlObj->fieldvalue='"'.$username.'","'.md5($password1).'","'.date('Y-m-d').'","SubAdmin","'.$master.'","'.$notification.'","'.$tripsheet.'","'.$accounting.'","'.$accpay.'","'.$report.'","'.$address.'","'.$phoneno.'","1"';*/
			
			$sqlObj->fieldname='(e_id,name,password,date,type,address,phone,status,master_status,client_status,vendor_status,vehicle_status,product_status,user_status,kopra_status,sku_status,filmroll_status,brand_status,agmark_status,openingbal_status,hr_status,
  branch_status,department_status,designation_status,employee_status,timesheet_status,leave_status,payroll_status,setting_status,purchase_status,oilpurchase_status,koprapurchase_status,purcahsedashboard_status,inventory_status,warehousestock_status,skustock_status,pinnakustock_status,stationary_status,package_status,addpackage_status,packagelist_status,agmarkno_status,sales_status,addsales_status,
  saleslist_status,tripsheet_status,addtripsheet_status,tripsheetpending_status,tripsheetfinished_status,vehiclemaster_status,vehiclenotif_status,vehiclemilage_status,account_status,accountgroup_status,ledgergroup_status,
 receipt_status,voucher_status,advance_status,acpayable_status,cashbook_status,bankbook_status,journal_status,plac_status)';

			$sqlObj->fieldvalue='"'.$emp_name.'","'.$username.'","'.md5($password1).'","'.date('Y-m-d').'","SubAdmin","'.$address.'","'.$phoneno.'","1","'.$master.'","'.$client.'","'.$vendor.'","'.$vehicle.'","'.$product.'","'.$manageuser.'","'.$kopra.'","'.$sku.'","'.$filmroll.'","'.$brand.'","'.$agmark.'","'.$openingbalance.'","'.$hr.'","'.$branch.'","'.$department.'","'.$designation.'","'.$employee.'","'.$timesheet.'","'.$leave.'","'.$payroll.'","'.$settings.'","'.$purchase.'","'.$oilpurchase.'","'.$koprapurchase.'","'.$purchasedashboard.'","'.$inventory.'","'.$warehousestock.'","'.$skustock.'","'.$pinnakustock.'","'.$stationarystock.'","'.$packaging.'","'.$addpackage.'","'.$packagelist.'","'.$Agmarknostatus.'","'.$salebilling.'","'.$addsales.'","'.$saleslist.'","'.$tripsheetmgmt.'","'.$addtripsheet.'","'.$tripsheetpending.'","'.$tripsheetfinished.'","'.$vehiclemgmt.'","'.$vehiclenotification.'","'.$vehiclemilagemgmt.'","'.$accounts.'","'.$accountgroup.'","'.$ledgermgmt.'","'.$receipt.'","'.$voucher.'","'.$advance.'","'.$acpayable.'","'.$cashbook.'","'.$bankbook.'","'.$journal.'","'.$placs.'"';
			
			
			
		
	echo $qsy= "insert into ".$tablename.$sqlObj->fieldname." values(".$sqlObj->fieldvalue.")";
										
			$CreateClient 	= mysql_query($qsy);
			
			$lastid = mysql_insert_id();
			}
			
			
			$cnt = count($clientcode);		
			
					for($i=0;$i<$cnt;$i++)
					{
					
					//echo $clientcode[$i];
						//echo "insert into cf_user_clientid (user_id,client_code) values('$lastid','".$clientcode[$i]."')";
						/*$sqldistrict = mysql_query("select district from cf_district where district_id = '$districtid'");				
						$rw = mysql_fetch_array($sqldistrict);
						$distict = $rw['district'];
						
						$sub = substr($distict, 0, 5);
						$str = strtoupper($sub);					
						$code = $clientcode.'-'.$str.'/'.$nwcodeno;*/
						
						$sqlclient = mysql_query("insert into cf_user_clientid (user_id,client_code) values('$lastid','".$clientcode[$i]."')");
					}
		//	header("location:user_list.php");
			
			
			
}

			$name = '';
			$address = '';
			$phoneno = '';
			$master= '';
			$client='';
			$vendor='';
			$vehicle='';
			$product='';
			$kopra='';
			$sku='';
			$manageuser='';
			$brand='';  
			$filmroll='';
			$agmark='';
			$openingbalance='';
			$tripsheet='';
			$hr='';
			$branch='';
			$department='';
			$designation='';
			$employee='';
			$timesheet='';
			$leave='';
			$payroll='';
			$settings='';
			$purchase='';
			$oilpurchase='';
			$koprapurchase='';
			$purchasedashboard='';  
			$inventory='';
			$warehousestock='';
			$skustock='';
			$pinnakustock='';
			$stationarystock='';  
			$packaging='';
			$addpackage='';
			$packagelist=''; 
			$Agmarknostatus=''; 
			$salebilling='';
			$addsales='';
			$saleslist='';  
			$tripsheetmgmt='';
			$addtripsheet='';
			$tripsheetpending='';
			$tripsheetfinished='';  
			$vehiclemgmt='';
			$vehiclenotification='';
			$vehiclemilagemgmt='';  
			$accounts='';
			$accountgroup='';
			$ledgermgmt='';
			$receipt='';
			$voucher='';
			$advance='';
			$acpayable='';
			$cashbook='';
			$bankbook='';
			$journal='';
			$placs='';
						
			$getclientid=array();
			if(isset($_REQUEST['user_main'])){
			
				$id=$_REQUEST['user_main'];
				$tablename='cf_user_07';
				$sqlObj->tablename="cf_user_07";
				$condition=" where 	userid='$id'";
				$sqlObj->condition=$condition;
				$sqlObj->fieldvalue="*";
				$fieldvalue=$sqlObj->fieldvalue;
				$sql=$sqlObj->SelectTable();
				$name= $sql['name'];
				$address= $sql['address'];
				$phoneno= $sql['phone'];
				$master= $sql['master_status'];
				$client= $sql['client_status'];
				$vendor= $sql['vendor_status'];
				$vehicle= $sql['vehicle_status'];
				$product= $sql['product_status'];
				$kopra=$sql['kopra_status'];
				$sku=$sql['sku_status'];
				$manageuser=$sql['user_status'];
				$filmroll=$sql['filmroll_status'];
				$openingbalance=$sql['openingbal_status'];
				$brand=$sql['brand_status'];  
				$agmark=$sql['agmark_status'];
				$branch=$sql['branch_status'];
				$department=$sql['department_status'];
				$designation=$sql['designation_status'];
				$employee=$sql['employee_status'];
				$timesheet=$sql['timesheet_status'];
				$leave=$sql['leave_status'];
				$payroll=$sql['payroll_status'];
				$settings=$sql['setting_status'];
				$hr=$sql['hr_status'];
				$purchase=$sql['purchase_status'];
				$oilpurchase=$sql['oilpurchase_status'];
				$koprapurchase=$sql['koprapurchase_status'];  
				$purchasedashboard=$sql['purcahsedashboard_status'];  
				$inventory=$sql['master_status'];
				$warehousestock=$sql['warehousestock_status'];
				$skustock=$sql['skustock_status'];
				$pinnakustock=$sql['pinnakustock_status'];
				$stationarystock=$sql['stationary_status'];
				$inventory=$sql['inventory_status'];  
				$packaging=$sql['package_status'];
				$addpackage=$sql['addpackage_status'];
				$packagelist=$sql['packagelist_status'];  
				$salebilling=$sql['sales_status'];
				$addsales=$sql['addsales_status'];
				$saleslist=$sql['saleslist_status'];  
				$tripsheetmgmt=$sql['tripsheet_status'];
				$addtripsheet=$sql['addtripsheet_status'];
				$tripsheetpending=$sql['tripsheetpending_status'];
				$tripsheetfinished=$sql['tripsheetfinished_status'];  
				$vehiclemgmt=$sql['vehiclemaster_status'];
				$vehiclenotification=$sql['vehiclenotif_status'];
				$vehiclemilagemgmt=$sql['vehiclemilage_status'];  
				$accounts=$sql['account_status'];
				$accountgroup=$sql['accountgroup_status'];
				$ledgermgmt=$sql['ledgergroup_status'];
				$receipt=$sql['receipt_status'];
				$voucher=$sql['voucher_status'];
				$advance=$sql['advance_status'];
				$acpayable=$sql['acpayable_status'];
				$cashbook=$sql['cashbook_status'];
				$bankbook=$sql['bankbook_status'];
				$journal=$sql['journal_status'];
				$placs=$sql['plac_status'];
				
				$sqlcilent = mysql_query("select * from cf_user_clientid where user_id = '$id'");
				
				while($rw = mysql_fetch_array($sqlcilent))
				{
					$getclientid[] = $rw['client_code'];
				}
				
				
				}
				
		if(isset($_REQUEST['edit'])){
			if(isset($_POST['username'])){
			$username=addslashes($_POST['username']);
			}
			
			if(isset($_POST['address'])){
			$address=addslashes($_POST['address']);
			}
			
			if(isset($_POST['phoneno'])){
			$phoneno=addslashes($_POST['phoneno']);
			}
			
			if(isset($_POST['master']))
			{
			$master=1;
			}
			else
			{
			$master=0;
			}
						
			if(isset($_POST['client']))
			{
			$client=1;
			}
			else
			{
			$client=0;
			}
			
			if(isset($_POST['vendor']))
			{
			$vendor=1;
			}
			else
			{
			$vendor=0;
			}
			
			if(isset($_POST['vehicle']))
			{
			$vehicle=1;
			}
			else
			{
			$vehicle=0;
			}
			
			if(isset($_POST['product']))
			{
			$product=1;
			}
			else
			{
			$product=0;
			}
			
			if(isset($_POST['kopra']))
			{
			$kopra=1;
			}
			else
			{
			$kopra=0;
			}
			
			if(isset($_POST['sku']))
			{
			$sku=1;
			}
			else
			{
			$sku=0;
			}
			
			
			if(isset($_POST['manageuser']))
			{
			$manageuser=1;
			}
			else
			{
			$manageuser=0;
			}
			
			if(isset($_POST['filmroll']))
			{
			$filmroll=1;
			}
			else
			{
			$filmroll=0;
			}
			
			
			
			
			if(isset($_POST['brand']))
			{
			$brand=1;
			}
			else
			{
			$brand=0;
			}
			
			if(isset($_POST['agmark']))
			{
			$agmark=1;
			}
			else
			{
			$agmark=0;
			}
			
			if(isset($_POST['openingbalance']))
			{
			$openingbalance=1;
			}
			else
			{
			$openingbalance=0;
			}
			
			
			if(isset($_POST['hr'])){
			$hr=1;
			}
			else
			{
			$hr=0;
			}
			
			if(isset($_POST['hr'])){
			$branch=1;
			}
			else
			{
			$branch=0;
			}
			
			if(isset($_POST['department'])){
			$department=1;
			}
			else
			{
			$department=0;
			}
			
			if(isset($_POST['designation'])){
			$designation=1;
			}
			else
			{
			$designation=0;
			}
			
			if(isset($_POST['employee'])){
			$employee=1;
			}
			else
			{
			$employee=0;
			}
			
			if(isset($_POST['timesheet'])){
			$timesheet=1;
			}
			else
			{
			$timesheet=0;
			}
			
			
			if(isset($_POST['leave'])){
			$leave=1;
			}
			else
			{
			$leave=0;
			}
			
			if(isset($_POST['payroll'])){
			$payroll=1;
			}
			else
			{
			$payroll=0;
			}
			
			if(isset($_POST['settings'])){
			$settings=1;
			}
			else
			{
			$settings=0;
			}
			
			if(isset($_POST['purchase'])){
			$purchase=1;
			}
			else
			{
			$purchase=0;
			}
			
			if(isset($_POST['oilpurchase'])){
			$oilpurchase=1;
			}
			else
			{
			$oilpurchase=0;
			}
			
			
			if(isset($_POST['koprapurchase'])){
			$koprapurchase=1;
			}
			else
			{
			$koprapurchase=0;
			}
			
			if(isset($_POST['purchasedashboard'])){
			$purchasedashboard=1;
			}
			else
			{
			$purchasedashboard=0;
			}		
			
			
			if(isset($_POST['inventory'])){
			$inventory=1;
			}
			else
			{
			$inventory=0;
			}
			
			if(isset($_POST['warehousestock'])){
			$warehousestock=1;
			}
			else
			{
			$warehousestock=0;
			}
			
			if(isset($_POST['skustock'])){
			$skustock=1;
			}
			else
			{
			$skustock=0;
			}
			
			if(isset($_POST['pinnakustock'])){
			$pinnakustock=1;
			}
			else
			{
			$pinnakustock=0;
			}
			
			if(isset($_POST['stationarystock'])){
			$stationarystock=1;
			}
			else
			{
			$stationarystock=0;
			}
						
			if(isset($_POST['packaging'])){
			$packaging=1;
			}
			else
			{
			$packaging=0;
			}
			
			if(isset($_POST['addpackage'])){
			$addpackage=1;
			}
			else
			{
			$addpackage=0;
			}
			
			if(isset($_POST['packagelist'])){
			$packagelist=1;
			}
			else
			{
			$packagelist=0;
			}
			
			if(isset($_POST['Agmarknostatus'])){
			$Agmarknostatus=1;
			}
			else
			{
			$Agmarknostatus=0;
			}
			
			if(isset($_POST['salebilling'])){
			$salebilling=1;
			}
			else
			{
			$salebilling=0;
			}
			
			
			
			if(isset($_POST['addsales'])){
			$addsales=1;
			}
			else
			{
			$addsales=0;
			}
			
			if(isset($_POST['saleslist'])){
			$saleslist=1;
			}
			else
			{
			$saleslist=0;
			}
			
							
			if(isset($_POST['tripsheetmgmt'])){
			$tripsheetmgmt=1;
			}
			else
			{
			$tripsheetmgmt=0;
			}
			
			if(isset($_POST['addtripsheet'])){
			$addtripsheet=1;
			}
			else
			{
			$addtripsheet=0;
			}
			
			if(isset($_POST['tripsheetpending'])){
			$tripsheetpending=1;
			}
			else
			{
			$tripsheetpending=0;
			}
			
			if(isset($_POST['tripsheetfinished'])){
			$tripsheetfinished=1;
			}
			else
			{
			$tripsheetfinished=0;
			}
			
			if(isset($_POST['vehiclemgmt'])){
			$vehiclemgmt=1;
			}
			else
			{
			$vehiclemgmt=0;
			}
			
			if(isset($_POST['vehiclenotification'])){
			$vehiclenotification=1;
			}
			else
			{
			$vehiclenotification=0;
			}
			
			if(isset($_POST['vehiclemilagemgmt'])){
			$vehiclemilagemgmt=1;
			}
			else
			{
			$vehiclemilagemgmt=0;
			}
			
			if(isset($_POST['accounts'])){
			$accounts=1;
			}
			else
			{
			$accounts=0;
			}
			
			if(isset($_POST['accountgroup'])){
			$accountgroup=1;
			}
			else
			{
			$accountgroup=0;
			}
			
			
			if(isset($_POST['ledgermgmt'])){
			$ledgermgmt=1;
			}
			else
			{
			$ledgermgmt=0;
			}
			
			if(isset($_POST['receipt'])){
			$receipt=1;
			}
			else
			{
			$receipt=0;
			}
			
			if(isset($_POST['voucher'])){
			$voucher=1;
			}
			else
			{
			$voucher=0;
			}
			
			if(isset($_POST['advance'])){
			$advance=1;
			}
			else
			{
			$advance=0;
			}
			
			if(isset($_POST['acpayable'])){
			$acpayable=1;
			}
			else
			{
			$acpayable=0;
			}
			
			if(isset($_POST['cashbook'])){
			$cashbook=1;
			}
			else
			{
			$cashbook=0;
			}
			
			if(isset($_POST['bankbook'])){
			$bankbook=1;
			}
			else
			{
			$bankbook=0;
			}
			
			if(isset($_POST['journal'])){
			$journal=1;
			}
			else
			{
			$journal=0;
			}
			
			if(isset($_POST['placs'])){
			$placs=1;
			}
			else
			{
			$placs=0;
			}
			
			
			$sqldel= mysql_query("delete from cf_user_clientid where user_id = '$id'");
				
				
			if(isset($_POST['client_code'])){
			  $clientcode=$_POST['client_code'];
				
			  $cnt = count($clientcode);
				
				for($i=0;$i<$cnt;$i++)
				{
					$sqlclient = mysql_query("insert into cf_user_clientid (user_id,client_code) values('$id','".$clientcode[$i]."')");
				}
				
			}
			
			
				
				
			$sqlObj->tablename=$tablename;
			if(isset($_POST['username']))
				{
			
				$result=mysql_query("update cf_user_07 set 
				  master_status  = '$master',
				  client_status='$client',
				  vendor_status='$vendor',
				  vehicle_status='$vehicle',
				  product_status='$product',
				  user_status='$manageuser',
				  kopra_status='$kopra',
				  sku_status='$sku',
				  filmroll_status='$filmroll',
				  brand_status='$brand',
				  agmark_status='$agmark',
				  openingbal_status='$openingbalance',
				  branch_status='$branch',
				  department_status='$department',
				  designation_status='$designation',
				  employee_status='$employee',
				  timesheet_status='$tripsheet',
				  leave_status='$leave',
				  payroll_status='$payroll',
				  setting_status='$settings',
				  oilpurchase_status='$oilpurchase',
				  koprapurchase_status='$koprapurchase',
				  purcahsedashboard_status='$purchasedashboard',
				  warehousestock_status='$warehousestock',
				  skustock_status='$skustock',
				  pinnakustock_status='$pinnakustock',
				  stationary_status='$stationarystock',
				  
				  
				  addpackage_status='$addpackage',
				  packagelist_status='$packagelist',
				  agmarkno_status='$Agmarknostatus',
				  addsales_status='$addsales',
				  saleslist_status='$saleslist',
				  addtripsheet_status='$addtripsheet',
				  tripsheetpending_status='$tripsheetpending',
				  tripsheetfinished_status='$tripsheetfinished',
				  vehiclenotif_status='$vehiclenotification',
				  vehiclemilage_status='$vehiclemilagemgmt',
				  accountgroup_status='$accountgroup',
				  ledgergroup_status='$ledgermgmt',
				  receipt_status='$receipt',
				  voucher_status='$voucher',
				  advance_status='$advance',
				  acpayable_status='$acpayable',
				  cashbook_status='$cashbook',
				  bankbook_status='$bankbook',
				  journal_status='$journal',
				  plac_status='$placs' where userid ='$id'");
					//header("location:user_list.php");
				}
						
			}
		


?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>OIL FILL</title>
<link href="css/styles.css" rel="stylesheet"  />
<link type="text/css" href="css_date/ui-lightness/jquery-ui-1.7.2.custom.css" rel="stylesheet" />
<script type="text/javascript" src="scripts_date/jquery.js"></script>
<script type="text/javascript" src="scripts_date/jquery-calendar-1.7.2.js"></script>

<script type="text/javascript">
<!--
function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
function validation(){
if(document.frmname.clientid.value==''){
alert("Select the Client name");
document.frmname.clientid.focus();
return false;
}
if(document.frmname.resellername.value==''){
alert("Enter the Reseller name");
document.frmname.resellername.focus();
return false;
}
if(document.frmname.consperson.value==''){
alert("Enter the Concerned Person");
document.frmname.consperson.focus();
return false;
}

if(document.frmname.locationid.value==''){
alert("Enter the location");
document.frmname.locationid.focus();
return false;
}

if(document.frmname.phoneno.value==''){
alert("Enter the Phone No");
document.frmname.phoneno.focus();
return false;
}



/*var cnt=document.getElementById('divcnt').value;chasisnum1 enginenum1
for(i=1;i<=cnt;i++){alert(document.getElementById('vehiclenum'+i).value);
if(document.getElementById('vehiclenum'+i)){
if(document.getElementById('vehiclenum'+i).value==''){
alert("Enter the Vehicle Number");
document.getElementById('vehiclenum'+i).focus();
return false;
}
}
}*/
}
</script>


<style>
.lableentrytext{
font-size: 12px;
color: #505050;
clear: both;
margin-bottom: 5px;
text-transform: capitalize;
}
</style>

<style  type="text/css">
/* Menu container */
.menu	{
	width:300px;
	/*height:175px;*/
	
	padding:10px 5px 10px 5px;
	margin:12px 12px 12px 50px;
	}

/* Menu styles */
.menu ul
	{
	margin:0px;
	padding:0px;
	}
.menu li
	{
	margin:0px 0px 0px 5px;
	padding:0px;
	list-style-type:none;
	text-align:left;
	font-family:Arial,Helvetica,sans-serif;
	font-size:13px;
	font-weight:normal;
	}

/* Submenu styles */

.menu li li
	{ margin:0px 0px 0px 16px; }

/* Symbol styles */
.menu .symbol-item,
.menu .symbol-open,
.menu .symbol-close
	{
	float:left;
	width:16px;
	height:1em;
	background-position:left center;
	background-repeat:no-repeat;
	}

/* Menu line styles */
.menu li.open  { font-weight:bold; }
.menu li.close { font-weight:normal; }

.statuscheck {float:left; padding-right:15px;display:table;   }
.statuscheck li {font-size:12px;margin-bottom:15px; }

</style>

<SCRIPT language="javascript">

$(function(){
 
     // Master select / deselect functionality	
    $("#selectmaster").click(function () {
          $('.case').attr('checked', this.checked);
    });
 
    // if all checkbox are selected, check the selectall checkbox
    // and viceversa
    $(".case").click(function(){
 
        if($(".case").length == $(".case:checked").length) {
            $("#selectmaster").attr("checked", "checked");
        } else {
            $("#selecttmaster").removeAttr("checked");
        }
 
    });
	
	 // End Master select / deselect functionality	
	
	 // Tripsheet select / deselect functionality	
	 $("#selecthr").click(function () {
          $('.casehr').attr('checked', this.checked);
    });
 
    $(".casehr").click(function(){
 
        if($(".casehr").length == $(".casehr:checked").length) {
            $("#selecthr").attr("checked", "checked");
        } else {
            $("#selecthr").removeAttr("checked");
        }
 
    });
	// End Tripsheet select / deselect functionality	
	
	 // Account Payable select / deselect functionality	
	 $("#selectpurchase").click(function () {
          $('.casepurchase').attr('checked', this.checked);
    });
 
    $(".casepurchase").click(function(){
 
        if($(".casepurchase").length == $(".casepurchase:checked").length) {
            $("#selectpurchase").attr("checked", "checked");
        } else {
            $("#selectpurchase").removeAttr("checked");
        }
 
    });
	// End Account Payable select / deselect functionality	
	
	 // Accounting select / deselect functionality	
	 $("#selectinventory").click(function () {
          $('.caseinventory').attr('checked', this.checked);
    });
 
    $(".caseinventory").click(function(){
 
        if($(".caseinventory").length == $(".caseinventory:checked").length) {
            $("#selectinventory").attr("checked", "checked");
        } else {
            $("#selectinventory").removeAttr("checked");
        }
 
    });
	// End Accounting select / deselect functionality	
	
	 // Report select / deselect functionality	
	 $("#selectpackage").click(function () {
          $('.casepackage').attr('checked', this.checked);
    });
 
    $(".casepackage").click(function(){
 
        if($(".casepackage").length == $(".casepackage:checked").length) {
            $("#selectpackage").attr("checked", "checked");
        } else {
            $("#selectpackage").removeAttr("checked");
        }
 
    });
	// End Report select / deselect functionality	
	
	// Report select / deselect functionality	
	 $("#selectpackage").click(function () {
          $('.casepackage').attr('checked', this.checked);
    });
 
    $(".casepackage").click(function(){
 
        if($(".casepackage").length == $(".casepackage:checked").length) {
            $("#selectpackage").attr("checked", "checked");
        } else {
            $("#selectpackage").removeAttr("checked");
        }
 
    });
	
	 $("#selectsales").click(function () {
          $('.casesales').attr('checked', this.checked);
    });
 
    $(".casesales").click(function(){
 
        if($(".casesales").length == $(".casesales:checked").length) {
            $("#selectsales").attr("checked", "checked");
        } else {
            $("#selectsales").removeAttr("checked");
        }
 
    });
	
	$("#selectrip").click(function () {
          $('.casetrip').attr('checked', this.checked);
    });
 
    $(".casetrip").click(function(){
 
        if($(".casetrip").length == $(".casetrip:checked").length) {
            $("#selectrip").attr("checked", "checked");
        } else {
            $("#selectrip").removeAttr("checked");
        }
 
    });
	
	$("#selectvehicle").click(function () {
          $('.casevehicle').attr('checked', this.checked);
    });
 
    $(".casevehicle").click(function(){
 
        if($(".casevehicle").length == $(".casevehicle:checked").length) {
            $("#selectvehicle").attr("checked", "checked");
        } else {
            $("#selectvehicle").removeAttr("checked");
        }
 
    });
	
	$("#selectaccount").click(function () {
          $('.caseaccount').attr('checked', this.checked);
    });
 
    $(".caseaccount").click(function(){
 
        if($(".caseaccount").length == $(".caseaccount:checked").length) {
            $("#selectaccount").attr("checked", "checked");
        } else {
            $("#selectaccount").removeAttr("checked");
        }
 
    });
	
	
	
	
	
	
	// End Report select / deselect functionality	
	
	
	
	
});
</SCRIPT>
</head>

<body>
<div class="wrapper">
  <div>
<?php 
	include("header.php");
?>
 
</div>
 
 
 <div class="tabbedArea">
  
  <div class="tabBody">
   <h1>Add User</h1>
   <form name="frmname" method="post" action="">
   <div class="addEmp" style="margin-bottom:0px; border-bottom:0px solid;width:1000px;">
        <table width="70%" border="0" cellspacing="0" cellpadding="10">
          <tr>
            <td valign="top">
           
            <div class="form1">
            
             <?php /*?><div>     
      			<p class="input1">Client Code<span style="color:#FF3300">*</span></p>
           <select name="client_code[]"  id="clientcode" size="5"  multiple="multiple" style="width:220px;" >
   
  <?php //$getdistrictid
           		$sqlres = mysql_query("select * from cf_client");
				while($row = mysql_fetch_array($sqlres))
				{ ?>
					<option value="<?=$row['client_newcode']?>" <?php if(in_array($row['client_newcode'],$getclientid)){?> selected="selected"<? }?>>
        				<?=$row['client_newcode']?>
        			</option>		
				<?php }
			?>	
    </select>
         </div>  <?php */?>
		 
            <div>     
      			<p class="input1 input3">Employee Name<span style="color:#FF3300">*</span></p>
           <select name="emp_name"  id="emp_name"  style="width:220px;" class="input1" >
   
  <?php //$getdistrictid
           		$sqlemp = mysql_query("select * from cf_employee");
				while($emprow = mysql_fetch_array($sqlemp))
				{ ?>
					<option value="<?=$emprow['e_id']?>" >
        				<?=$emprow['e_fname']?>
        			</option>		
				<?php }
			?>	
    </select>
         </div> 
          	<div  class="select1">
     			<p class="input1">User Name<span style="color:#FF3300">*</span></p>
     				<input type="text" name="username" class="input1 input3" value="<?=$name?>" <?php if(!empty($_REQUEST['user_main'])) { ?> readonly="readonly"  <?php } ?>/>
      		</div>
           
           <?php 
		   		if(empty($_REQUEST['user_main']))
				{
		   ?>
           
           <div>     
      			<p class="input1">Password<span style="color:#FF3300">*</span></p><input type="text" name="newpassword" class="input1 input3" />
     	   </div>
           <?php } ?>
           
            <div>     
      			<p class="input1">Address</p><textarea name="address" class="input1"><?=$address?></textarea>
     	   </div>
            
           <div>     
      			<p class="input1">Phone No<span style="color:#FF3300">*</span></p><input type="text" name="phoneno" class="input1 input3" value="<?=$phoneno?>" >
     	   </div>
                               
           
            
          </div>
        </td>
            <td valign="top">
            <div class="form1" style="width:auto;">
            
            
            <div class="menu" style="width:auto;margin-left:0px;"> 
            
<ul id="example1" class="statuscheck">
<li style="font-weight:bold"><input type="checkbox"  style="float:left;" name="master" id="selectmaster" value="1" <?php if($master == '1') { ?>  checked="checked" <?php } ?> />Master
  <ul>
      <li><input type="checkbox" name="client" class="case" style="float:left;" value="1" <?php if($client == '1') { ?>  checked="checked" <?php } ?> />Client</li>
      <li><input type="checkbox" name="vendor" class="case" style="float:left;" value="1" <?php if($vendor == '1') { ?>  checked="checked" <?php } ?> />Vendor</li>
      <li><input type="checkbox" name="vehicle" class="case" style="float:left;" value="1" <?php if($vehicle == '1') { ?>  checked="checked" <?php } ?> />Vehicle</li>
      <li><input type="checkbox" name="product" class="case" style="float:left;" value="1" <?php if($product == '1') { ?>  checked="checked" <?php } ?> />Product</li>
      <li><input type="checkbox" name="kopra" class="case" style="float:left;" value="1" <?php if($kopra == '1') { ?>  checked="checked" <?php } ?> />Kopra</li>
      <li><input type="checkbox" name="sku" class="case" style="float:left;" value="1" <?php if($sku == '1') { ?>  checked="checked" <?php } ?> />Sku</li>
	  <li><input type="checkbox" name="filmroll" class="case" style="float:left;" value="1" <?php if($filmroll == '1') { ?>  checked="checked" <?php } ?> />Flimroll</li>
      <li><input type="checkbox" name="manageuser" class="case" style="float:left;" value="1" <?php if($manageuser == '1') { ?>  checked="checked" <?php } ?> />Manage User</li> 
	  <li><input type="checkbox" name="brand" class="case" style="float:left;" value="1" <?php if($manageuser == '1') { ?>  checked="checked" <?php } ?> />Brand</li> 
	  <li><input type="checkbox" name="agmark" class="case" style="float:left;" value="1" <?php if($manageuser == '1') { ?>  checked="checked" <?php } ?> />Agmark</li> 
	  <li><input type="checkbox" name="openingbalance" class="case" style="float:left;" value="1" <?php if($openingbalance == '1') { ?>  checked="checked" <?php } ?> />Opening Balance</li> 
	</ul>
</li>

<li style="font-weight:bold"><input type="checkbox" name="hr" id="selecthr" value="1" style="float:left;" <?php if($hr == '1') { ?>  checked="checked" <?php } ?> />HR
  <ul>
  <li><input type="checkbox" name="branch" class="casehr" value="1" style="float:left;" <?php if($branch == '1') { ?>  checked="checked" <?php } ?> />Branch</li>
  <li><input type="checkbox" name="department" class="casehr" value="1" style="float:left;" <?php if($department == '1') { ?>  checked="checked" <?php } ?> />Department
</li>
  <li><input type="checkbox" name="designation" class="casehr" value="1" style="float:left;" <?php if($designation == '1') { ?>  checked="checked" <?php } ?> />Designation</li>
  <li><input type="checkbox" name="employee" class="casehr" value="1" style="float:left;" <?php if($employee == '1') { ?>  checked="checked" <?php } ?> />Employee</li>
  <li><input type="checkbox" name="timesheet" class="casehr" value="1" style="float:left;" <?php if($timesheet == '1') { ?>  checked="checked" <?php } ?> />Timesheet</li>
  <li><input type="checkbox" name="leave" class="casehr" value="1" style="float:left;" <?php if($leave == '1') { ?>  checked="checked" <?php } ?> />Leave</li>
  <li><input type="checkbox" name="payroll" class="casehr" value="1" style="float:left;" <?php if($payroll == '1') { ?>  checked="checked" <?php } ?> />Payroll</li>
  <li><input type="checkbox" name="settings" class="casehr" value="1" style="float:left;" <?php if($settings == '1') { ?>  checked="checked" <?php } ?> />Settings</li>
  </ul>
</li>

<li style="font-weight:bold"><input type="checkbox" name="purchase" id="selectpurchase" value="1" style="float:left;" <?php if($purchase == '1') { ?>  checked="checked" <?php } ?> />Purchase
  <ul>
 <li><input type="checkbox" name="oilpurchase" class="casepurchase" value="1" style="float:left;" <?php if($oilpurchase == '1') { ?>  checked="checked" <?php } ?> />Oil Purchase</li>
  <li><input type="checkbox" name="koprapurchase" class="casepurchase" value="1" style="float:left;" <?php if($koprapurchase == '1') { ?>  checked="checked" <?php } ?> />Kopra Purchase
</li>
<li><input type="checkbox" name="purchasedashboard" class="casepurchase" value="1" style="float:left;" <?php if($purchasedashboard == '1') { ?>  checked="checked" <?php } ?> />Purchase Dashboard
</li>
  </ul>
</li>

<li style="font-weight:bold"><input type="checkbox" name="inventory" id="selectinventory" value="1" style="float:left;" <?php if($inventory == '1') { ?>  checked="checked" <?php } ?> />Inventory
  <ul>
  <li><input type="checkbox" name="warehousestock" class="caseinventory" value="1" style="float:left;" <?php if($warehousestock == '1') { ?>  checked="checked" <?php } ?> />Warehouse Stock</li>
  <li><input type="checkbox" name="skustock" class="caseinventory" value="1" style="float:left;" <?php if($skustock == '1') { ?>  checked="checked" <?php } ?> />Sku Stock</li>
  <li><input type="checkbox" name="pinnakustock" class="caseinventory" value="1" style="float:left;" <?php if($pinnakustock == '1') { ?>  checked="checked" <?php } ?> />Pinnakku Stock</li>
  <li><input type="checkbox" name="stationarystock" class="caseinventory" value="1" style="float:left;" <?php if($stationarystock == '1') { ?>  checked="checked" <?php } ?> />Stationary Stock</li>
  </ul>
</li>

</ul>

          
         

            </div>
            </div>
            
            
            </td>
            
            <td valign="top">
            <div class="form1" style="width:auto;">
            
            
            <div class="menu" style="width:auto;margin-left:0px;"> 
            


<ul id="example1" class="statuscheck">

<li style="font-weight:bold"><input type="checkbox" name="packaging" id="selectpackage" value="1" style="float:left;" <?php if($packaging == '1') { ?>  checked="checked" <?php } ?> />Packaging
  <ul>
  <li><input type="checkbox" name="addpackage" class="casepackage" value="1" style="float:left;" <?php if($addpackage == '1') { ?>  checked="checked" <?php } ?> />Add Package</li>
  <li><input type="checkbox" name="packagelist" class="casepackage" value="1" style="float:left;" <?php if($packagelist == '1') { ?>  checked="checked" <?php } ?> />Package List</li>
  <li><input type="checkbox" name="Agmarknostatus" class="casepackage" value="1" style="float:left;" <?php if($Agmarknostatus == '1') { ?>  checked="checked" <?php } ?> />Agmark No Status</li>
  
  
  </ul>
</li>


<li style="font-weight:bold"><input type="checkbox" name="salebilling" id="selectsales" value="1" style="float:left;" <?php if($salebilling == '1') { ?>  checked="checked" <?php } ?> />Sales/Billing
  <ul>
  <li><input type="checkbox" name="addsales" class="casesales" value="1" style="float:left;" <?php if($addsales == '1') { ?>  checked="checked" <?php } ?> />Add Sales</li>
 <li><input type="checkbox" name="saleslist" class="casesales" value="1" style="float:left;" <?php if($saleslist == '1') { ?>  checked="checked" <?php } ?> />Sales List</li>
  </ul>
</li>

<li style="font-weight:bold"><input type="checkbox" name="tripsheetmgmt" id="selectrip" value="1" style="float:left;" <?php if($tripsheetmgmt == '1') { ?>  checked="checked" <?php } ?> />Tripsheet Mgmt
  <ul>
  <li><input type="checkbox" name="addtripsheet" class="casetrip" value="1" style="float:left;" <?php if($addtripsheet == '1') { ?>  checked="checked" <?php } ?> />Add Tripsheet</li>
 <li><input type="checkbox" name="tripsheetpending" class="casetrip" value="1" style="float:left;" <?php if($tripsheetpending == '1') { ?>  checked="checked" <?php } ?> />Tripsheet Pending</li>
 <li><input type="checkbox" name="tripsheetfinished" class="casetrip" value="1" style="float:left;" <?php if($tripsheetfinished == '1') { ?>  checked="checked" <?php } ?> />Tripsheet Pending</li>
  </ul>
</li>

<li style="font-weight:bold"><input type="checkbox" name="vehiclemgmt" id="selectvehicle" value="1" style="float:left;" <?php if($vehiclemgmt == '1') { ?>  checked="checked" <?php } ?> />Vehicle Mgmt
  <ul>
  <li><input type="checkbox" name="vehiclenotification" class="casevehicle" value="1" style="float:left;" <?php if($vehiclenotification == '1') { ?>  checked="checked" <?php } ?> />Vehicle Notification</li>
 <li><input type="checkbox" name="vehiclemilagemgmt" class="casevehicle" value="1" style="float:left;" <?php if($vehiclemilagemgmt == '1') { ?>  checked="checked" <?php } ?> />Vehicle Milage Mgmt</li>
  </ul>
</li>

<li style="font-weight:bold"><input type="checkbox" name="accounts" id="selectaccount" value="1" style="float:left;" <?php if($accounts == '1') { ?>  checked="checked" <?php } ?> />Accounts
  <ul>
  <li><input type="checkbox" name="accountgroup" class="caseaccount" value="1" style="float:left;" <?php if($accountgroup == '1') { ?>  checked="checked" <?php } ?> />Account Groups</li>
<li><input type="checkbox" name="ledgermgmt" class="caseaccount" value="1" style="float:left;" <?php if($ledgermgmt == '1') { ?>  checked="checked" <?php } ?> />Ledger Mgmt</li>
<li><input type="checkbox" name="receipt" class="caseaccount" value="1" style="float:left;" <?php if($receipt == '1') { ?>  checked="checked" <?php } ?> />Receipt</li>
<li><input type="checkbox" name="voucher" class="caseaccount" value="1" style="float:left;" <?php if($voucher == '1') { ?>  checked="checked" <?php } ?> />Voucher
</li>
<li><input type="checkbox" name="advance" class="caseaccount" value="1" style="float:left;" <?php if($advance == '1') { ?>  checked="checked" <?php } ?> />Advances</li>
<li><input type="checkbox" name="acpayable" class="caseaccount" value="1" style="float:left;" <?php if($acpayable == '1') { ?>  checked="checked" <?php } ?> />A/Cs Payable
</li>
<li><input type="checkbox" name="cashbook" class="caseaccount" value="1" style="float:left;" <?php if($cashbook == '1') { ?>  checked="checked" <?php } ?> />Cash Book</li>
<li><input type="checkbox" name="bankbook" class="caseaccount" value="1" style="float:left;" <?php if($bankbook == '1') { ?>  checked="checked" <?php } ?> />Bank Book</li>
<li><input type="checkbox" name="journal" class="caseaccount" value="1" style="float:left;" <?php if($journal == '1') { ?>  checked="checked" <?php } ?> />Journal</li>
<li><input type="checkbox" name="placs" class="caseaccount" value="1" style="float:left;" <?php if($placs == '1') { ?>  checked="checked" <?php } ?> />P&L A/Cs
</li>
  </ul>
</li>




</ul>

<br/>
          
         
             <div>
            &nbsp;
            </div>
            </div>
            </div>
            
            
            </td>
            
            
            
            
            
          </tr>
           <tr>
            <td colspan="2"><div class="searchField1">
        
           <?php
	 	if(isset($_REQUEST['user_main'])){
	  ?>
      <input name="edit" type="submit" class="input1" value="Edit" onClick="return validation();"/>
      <?php }else { ?>
     <input name="save" type="submit" class="input1" value="Save" onClick="return validation();"/>
     <?php } ?>

         <input type="button" class="input1" value="Cancel" >
        </div>
        </td>
          </tr>
        </table>
 

<div class="mand"><p>Fields marked <span style="color:#FF3300">*</span> are Mandatory</p></div>

   </form>
   </div>
 </div>
 <div class="footer"><p>Powered by <a href="http://www.aadhocc.co.uk/" target="_blank">Aadhocc</a></p></div>
 
</div>
<div class="quicLInksCover">
 <?php 
	include("leftlink.php");
?>

</div>
</body>
</html>


		






