getId(); $_user['status'] = $chamiloUser->getStatus(); $_user['uidReset'] = true; Session::write('_user', $_user); $uidReset = true; // Is user admin? if ($chamilo_user['admin'] === true) { $is_platformAdmin = true; Database::query("INSERT INTO admin values ('{$chamiloUser->getId()}')"); } Event::eventLogin($chamiloUser->getId()); MessageManager::sendNotificationByRegisteredUser($chamiloUser); } } else { $loginFailed = true; $uidReset = false; }