isLoggedIn())
{
header ("location: ../../login.php");
exit();
}
$display=new display($dbf->conn,$cfg_theme,$cfg_currency_symbol,$lang);
$display->displayTitle("$lang->manageSuppliers");
$f1=new form('manage_suppliers.php','POST','suppliers','475',$cfg_theme,$lang);
$f1->createInputField("$lang->searchForSupplier",'text','search','','24','375');
$f1->endForm();
$tableheaders=array("$lang->rowID","$lang->supplierName","$lang->address","$lang->phoneNumber","$lang->contact","$lang->email","$lang->other","$lang->updateSupplier","$lang->deleteSupplier");
$tablefields=array('id','supplier','address','phone_number','contact','email','other');
if(isset($_POST['search']))
{
$search=$_POST['search'];
echo "$lang->searchedForSupplier: $search";
$display->displayManageTable("$cfg_tableprefix",'suppliers',$tableheaders,$tablefields,'supplier',"$search",'supplier');
}
else
{
$display->displayManageTable("$cfg_tableprefix",'suppliers',$tableheaders,$tablefields,'','','supplier');
}
$dbf->closeDBlink();
?>