From b271177d4412bfb5d1474f7d2d1ef0990e65addd Mon Sep 17 00:00:00 2001 From: =?utf8?q?St=C3=A9phane=20Jacob?= Date: Sun, 8 Apr 2012 18:01:52 +0200 Subject: [PATCH] Displays proper url in auth-group-x login (Closes #1608). MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Stéphane Jacob --- ChangeLog | 3 +++ modules/auth.php | 4 +++- templates/core/password_prompt.tpl | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 37b1d76..41b5bfc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -6,6 +6,9 @@ Bug/Wish: * Admin: - #1604: Displays AX id on admin page -JAC + * Auth: + - #1608: Displays proper url in auth-group-x login -JAC + * Search: - #1572: Removes remaining results count from queries -JAC - #1574: Correctly displays State corps -GLN diff --git a/modules/auth.php b/modules/auth.php index d510da3..0d9e12b 100644 --- a/modules/auth.php +++ b/modules/auth.php @@ -118,8 +118,11 @@ class AuthModule extends PLModule */ function handler_groupex($page, $charset = 'utf8') { + $gpex_url = urldecode(Get::s('url')); + if (!S::logged()) { $page->assign('external_auth', true); + $page->assign('gpex_url', $gpex_url); $page->setTitle('Authentification'); $page->setDefaultSkin('group_login'); @@ -141,7 +144,6 @@ class AuthModule extends PLModule $this->load('auth.inc.php'); $gpex_pass = Get::s('pass'); - $gpex_url = urldecode(Get::s('url')); if (Get::has('session')) { if (strpos($gpex_url, '?') === false) { $gpex_url .= "?PHPSESSID=" . Get::s('session'); diff --git a/templates/core/password_prompt.tpl b/templates/core/password_prompt.tpl index 8dc634d..56e84e8 100644 --- a/templates/core/password_prompt.tpl +++ b/templates/core/password_prompt.tpl @@ -31,7 +31,7 @@ {else} la page que vous avez demandée {/if} - ({if t($external_auth)}{$smarty.server.HTTP_REFERER|truncate:120:"...":false}{else}{$globals->baseurl}/{$platal->pl_self()}{/if}) + ({if t($external_auth)}{$gpex_url|truncate:120:"...":false}{else}{$globals->baseurl}/{$platal->pl_self()}{/if}) nécessite une authentification.

{else} -- 2.1.4