add: Auth modules now accept a "returnUrl" form parameter when logging in or creating a new account. User will be redirected to the value in "returnUrl" after login / create account is complete.

add: L_LoginBox macro has a form.returnUrl template var that returns a user to the exact page they logged in from
This commit is contained in:
Doug Bell 2008-02-09 05:09:33 +00:00
parent 04da356822
commit 1f10f07338
8 changed files with 163 additions and 9 deletions

View file

@ -75,6 +75,14 @@ sub process {
$var{'logout.url'} = $session->url->page("op=auth;method=logout");
$var{'account.display.url'} = $session->url->page('op=auth;method=displayAccount');
$var{'logout.label'} = $i18n->get(49);
# A hidden field with the current URL
$var{'form.returnUrl'}
= WebGUI::Form::hidden( $session, {
name => 'returnUrl',
value => $session->url->page($session->env->get("QUERY_STRING")),
});
my $boxSize = $param[0];
$boxSize = 12 unless ($boxSize);
if (index(lc($session->env->get("HTTP_USER_AGENT")),"msie") < 0) {