<?php

include 'config/index.php';

include('module/index.php');

 $db = new Database();
 $con = $db->connect();

 $user = new User($con);

$date = new DateTime(); // current date and time
$c = $date->format('d M y, h:i a'); // 21 Dec 22, 08:39 pm

echo $user->updateLoginHistory($c);

session_unset();
session_destroy();

header('location:../login.php');

?>