} } }else if($_REQUEST['mode'] == 'edit'){ $title = "Edit Company"; if(empty($_REQUEST['id'])){ $error_msg .= "Error: No ID specified!\n"; }else{ if(!$company->get($_REQUEST['id'])){ $error_msg .= "Error retrieving company information!\n"; debug_message($company->getLastError()); } } if($_POST['save']){ $company->updateFromAssocArray($_POST); if($company->update()){ goBack(); }else{ $error_msg .= "Error updating Company!\n"; debug_message($company->getLastError()); } } }else if($_REQUEST['mode'] == 'delete'){ $title = "Delete Company"; if(!$company->get($_REQUEST['id'])){ $error_msg .= "Error retrieving company information!\n"; debug_message($company->getLastError()); } if($_POST['confirm']){