<?php

if(!isset($_SESSION['user_id']))
{
header("Location: ../admin/login.php");
exit;
}

function checkRole($roles)
{
if(!in_array($_SESSION['role_id'],$roles))
{
header("Location: ../admin/dashboard.php");
exit;
}
}

?>