_e('c_c_auth_login_action'); ?> " /></p> <p class="note"><?php _e('c_c_auth_must_accept_cookies_private_area'); ?> </p> <ul> <?php # début Okatea : lien page mot de passe oublié if ($okt->users->config->enable_forget_password_page) { ?> <li><a href="<?php echo html::escapeHTML(usersHelpers::getForgetPasswordUrl()); ?> "><?php _e('c_c_auth_forgot_password'); ?> </a></li> <?php } # fin Okatea : lien page mot de passe oublié ?> <?php # début Okatea : lien page inscription if ($okt->users->config->enable_register_page) { ?> <li><a href="<?php
/** * Affichage de la page de récupération de mot de passe perdu. * */ public function usersForgetPassword() { # module actuel $this->okt->page->module = 'users'; $this->okt->page->action = 'forget_password'; # page désactivée ? if (!$this->okt->users->config->enable_forget_password_page) { $this->serve404(); } # allready logged if (!$this->okt->user->is_guest && !defined('OKT_DONT_REDIRECT_IF_LOGGED')) { $this->performRedirect(); } $password_sended = false; $password_updated = false; if (!empty($_POST['form_sent']) && !empty($_POST['email'])) { if ($this->okt->user->forgetPassword($_POST['email'], html::escapeHTML($this->okt->config->app_host . usersHelpers::getForgetPasswordUrl()))) { $password_sended = true; } } if (!empty($_GET['action']) && $_GET['action'] == 'validate_password' && !empty($_GET['key']) && !empty($_GET['uid'])) { $uid = intval($_GET['uid']); $key = $_GET['key']; if ($this->okt->user->validatePasswordKey($uid, $key)) { $password_updated = true; } } # title tag $this->okt->page->addTitleTag(__('c_c_auth_request_password')); # titre de la page $this->okt->page->setTitle(__('c_c_auth_request_password')); # titre SEO de la page $this->okt->page->setTitleSeo(__('c_c_auth_request_password')); # fil d'ariane if (!$this->isDefaultRoute(__CLASS__, __FUNCTION__)) { $this->okt->page->breadcrumb->add(__('c_c_auth_request_password'), usersHelpers::getForgetPasswordUrl()); } # affichage du template echo $this->okt->tpl->render($this->okt->users->getForgottenPasswordTplPath(), array('password_sended' => $password_sended, 'password_updated' => $password_updated)); }