*/ $neededObjAr = array(AMA_TYPE_AUTHOR => array('layout')); require_once ROOT_DIR . '/include/module_init.inc.php'; $self = whoami(); include_once 'include/author_functions.inc.php'; /* * YOUR CODE HERE */ require_once ROOT_DIR . '/include/Forms/UserProfileForm.inc.php'; $languages = Translator::getLanguagesIdAndName(); if (isset($_SERVER['REQUEST_METHOD']) && $_SERVER['REQUEST_METHOD'] == 'POST') { $form = new UserProfileForm($languages); $form->fillWithPostData(); $password = trim($_POST['password']); $passwordcheck = trim($_POST['passwordcheck']); if (DataValidator::validate_password_modified($password, $passwordcheck) === FALSE) { $message = translateFN('Le password digitate non corrispondono o contengono caratteri non validi.'); header("Location: edit_author.php?message={$message}"); exit; } if ($form->isValid()) { $userObj->fillWithArrayData($_POST); MultiPort::setUser($userObj, array(), true); /* unset $_SESSION['service_level'] to reload it with the correct user language translation */ unset($_SESSION['service_level']); $help = translateFN('Dati salvati'); /*$navigationHistoryObj = $_SESSION['sess_navigation_history']; $location = $navigationHistoryObj->lastModule(); header('Location: ' . $location); exit();*/ }