Changeset 782
- Timestamp:
- 02/02/10 02:34:38 (14 years ago)
- Location:
- LATMOS-Accounts-Web
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LATMOS-Accounts-Web/lib/LATMOS/Accounts/Web/Controller/Root.pm
r651 r782 40 40 username => $c->req->param('username'), 41 41 password => $c->req->param('password')})) { 42 my $redirurl = $c->uri_for($c->req->param('loguri') || '/'); 43 $redirurl = $c->uri_for('/') if ($redirurl =~ m:^/login:); 42 my $redirurl = $c->uri_for($c->req->param('loguri') || '/'); 44 43 $c->res->redirect($redirurl || $c->uri_for('/')); 45 44 } else { … … 47 46 } 48 47 } 48 my ($redirurl) = grep { $_ } ( 49 $c->req->param('loguri'), 50 ($c->req->path ? '/' . $c->req->path : undef), 51 $c->uri_for('/'), 52 ); 53 $c->stash->{redirurl} = $redirurl; 49 54 } 50 55 -
LATMOS-Accounts-Web/root/html/login.tt
r600 r782 2 2 <form action="[% c.uri_for('/login') %]" method="POST"> 3 3 <p>Vous devez vous connecter:</p> 4 <input type="hidden" name="loguri" value="[% '/' _ c.req.path| html %]">4 <input type="hidden" name="loguri" value="[% redirurl | html %]"> 5 5 <table border="0" align="center"> 6 6 <tr>
Note: See TracChangeset
for help on using the changeset viewer.