<?php
include('../include/config.php');
//error_reporting(0);
session_start();
$iduser= $_SESSION['user_idd'];

$date = new DateTime("now", new DateTimeZone('Africa/Nairobi') );
$timenow=$date->format('Y-m-d H:i:s');
$timenow2=$date->format('Y-m-d');
$month=$date->format('M');

if(isset($_POST['id']))
 {
 $tu = addslashes($_POST['tu']);
 $id=addslashes($_POST["id"]);

$date = new DateTime("now", new DateTimeZone('Africa/Nairobi') );
$timenow=$date->format('Y-m-d H:i:s');
$timenow2=$date->format('Y-m-d');
$month=$date->format('M');


$sql=mysqli_query($con,"UPDATE Fees SET Tution='$tu' WHERE count='$id'");
if($sql)
{
//$msgg='updated company profile details';
//$sql3=mysqli_query($con,"INSERT INTO activity(user,Action,Tim,Dat,shortmsg,Month)values('$iduser','$msgg','$timenow','$timenow2','update','$month')");
// if($sql3)
// { }
echo "updated";
}else
{
echo "Unable to save data";	
}	
 }
 ?>