$additional_param .= "&cmd=" . $additional; } else { $additional_param = ''; } $link = 'ilias.php?baseClass=' . ilShopLinkBuilder::$linkArray[strtolower($class)]['baseClass'] . '&cmdClass=' . strtolower(ilShopLinkBuilder::$linkArray[strtolower($class)]['cmdClass']) . $additional_param; ilUtil::redirect($link); } } } // imprint has no ref id... if ($target_type == "impr") { ilUtil::redirect('ilias.php?baseClass=ilImprintGUI'); } // goto is not granted? include_once "Services/Init/classes/class.ilStartUpGUI.php"; if (!ilStartUpGUI::_checkGoto($_GET["target"])) { // if anonymous: go to login page if ($ilUser->getId() == ANONYMOUS_USER_ID) { ilUtil::redirect("login.php?target=" . $orig_target . "&cmd=force_login&lang=" . $ilUser->getCurrentLanguage()); } else { // message if target given but not accessible $tarr = explode("_", $_GET["target"]); if ($tarr[0] != "pg" && $tarr[0] != "st" && $tarr[1] > 0) { ilUtil::sendFailure(sprintf($lng->txt("msg_no_perm_read_item"), ilObject::_lookupTitle(ilObject::_lookupObjId($tarr[1]))), true); } ilUtil::redirect('ilias.php?baseClass=ilPersonalDesktopGUI'); } } // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! // // FOR NEW OBJECT TYPES:
/** * @param string $password */ public function login($password) { /** * @var $lng ilLanguage */ global $lng; ilStartUpGUI::initStartUpTemplate(array('tpl.usr_registered.html', 'Services/Registration'), true); $this->tpl->setVariable('TXT_PAGEHEADLINE', $this->lng->txt('registration')); $this->tpl->setVariable("TXT_WELCOME", $lng->txt("welcome") . ", " . $this->userObj->getTitle() . "!"); if (($this->registration_settings->getRegistrationType() == IL_REG_DIRECT || $this->registration_settings->getRegistrationType() == IL_REG_CODES || $this->code_was_used) && !$this->registration_settings->passwordGenerationEnabled()) { $this->tpl->setCurrentBlock('activation'); $this->tpl->setVariable('TXT_REGISTERED', $lng->txt('txt_registered')); $this->tpl->setVariable('FORMACTION', 'login.php?cmd=post&target=' . ilUtil::stripSlashes($_GET['target'])); if (ilSession::get('forceShoppingCartRedirect')) { $this->tpl->setVariable('FORMACTION', './login.php?forceShoppingCartRedirect=1'); } $this->tpl->setVariable('TARGET', 'target="_parent"'); $this->tpl->setVariable('TXT_LOGIN', $lng->txt('login_to_ilias')); $this->tpl->setVariable('USERNAME', $this->userObj->getLogin()); $this->tpl->setVariable('PASSWORD', $password); $this->tpl->parseCurrentBlock(); } else { if ($this->registration_settings->getRegistrationType() == IL_REG_APPROVE) { $this->tpl->setVariable('TXT_REGISTERED', $lng->txt('txt_submitted')); if (IS_PAYMENT_ENABLED == true) { if (ilSession::get('forceShoppingCartRedirect')) { $this->tpl->setCurrentBlock('activation'); include_once 'Services/Payment/classes/class.ilShopLinkBuilder.php'; $shop_link = new ilShopLinkBuilder(); $this->tpl->setVariable('FORMACTION', $shop_link->buildLink('ilshopshoppingcartgui', '_forceShoppingCartRedirect_user='******'TARGET', 'target=\'_parent\''); $this->lng->loadLanguageModule('payment'); $this->tpl->setVariable('TXT_LOGIN', $lng->txt('pay_goto_shopping_cart')); $this->tpl->parseCurrentBlock(); $this->lng->loadLanguageModule('registration'); } } } else { if ($this->registration_settings->getRegistrationType() == IL_REG_ACTIVATION) { $login_url = './login.php?cmd=force_login&lang=' . $this->userObj->getLanguage(); $this->tpl->setVariable('TXT_REGISTERED', sprintf($lng->txt('reg_confirmation_link_successful'), $login_url)); $this->tpl->setVariable('REDIRECT_URL', $login_url); } else { $this->tpl->setVariable('TXT_REGISTERED', $lng->txt('txt_registered_passw_gen')); } } } }
/** * This form is used to show a message to the user. * @param string $text */ public function showMessageForm($text) { ilStartUpGUI::initStartUpTemplate('tpl.pwassist_message.html', true); $this->tpl->setVariable('TXT_PAGEHEADLINE', $this->lng->txt('password_assistance')); $this->tpl->setVariable('IMG_PAGEHEADLINE', ilUtil::getImagePath('icon_auth_b.png')); $this->tpl->setVariable('TXT_TEXT', str_replace("\\n", '<br />', $text)); $this->tpl->show(); }