isLoggedIn())
{
header ("location: ../login.php");
exit();
}
$display=new display($dbf->conn,$cfg_theme,$cfg_currency_symbol,$lang);
$display->displayTitle("$lang->manageUsers");
$f1=new form('manage_users.php','POST','users','400',$cfg_theme,$lang);
$f1->createInputField("$lang->searchForUser",'text','search','','24','300');
$f1->endForm();
$tableheaders=array("$lang->rowID","$lang->lastName","$lang->firstName","$lang->username","$lang->password","$lang->type","$lang->updateUser","$lang->deleteUser");
$tablefields=array('id','last_name','first_name','username','password','type');
if(isset($_POST['search']))
{
$search=$_POST['search'];
echo "$lang->searchedForUser: $search";
$display->displayManageTable("$cfg_tableprefix",'users',$tableheaders,$tablefields,'username',"$search",'last_name');
}
else
{
$display->displayManageTable("$cfg_tableprefix",'users',$tableheaders,$tablefields,'','','last_name');
}
$dbf->closeDBlink();
?>