/******************************************************************************/ /* Update / Add / AddAsNew functionality /******************************************************************************/ if ($formAction != '') { $redirect = false; if (isset($_POST['password']) && trim($_POST['password']) != '') { $_POST['password'] = $pageObject->encrypt($_POST['password']); } else { unset($_POST['password']); } $processResult = $pageObject->processForm($formAction, $_POST, $redirect); $smarty->assign('processResult', $processResult); if ($processResult != 0) { $pageObject->setAdministratorAccess($id_administratoraccess, $formAction); } $pageObject->redirect($formAction); } /******************************************************************************/ /* Get edit data /******************************************************************************/ if ($pageObject->id != '') { $pageObject->getEditData($editData); $smarty->assign('editData', $editData); $pageObject->getAdministratorAccessIds($adminAcceessData); $smarty->assign('adminAcceessData', $adminAcceessData); } /******************************************************************************/ /******************************************************************************/ $smarty->assign('formAction', $formAction); $smarty->assign('formUrl', $pageObject->getEditFormUrl()); /******************************************************************************/