$ctx->{path_info} = $self->cgi->path_info;
$ctx->{opac_root} = $ctx->{base_path} . "/opac"; # absolute base url
$ctx->{is_staff} = ($self->apache->headers_in->get('User-Agent') =~ 'oils_xulrunner');
+ $ctx->{home_page} = 'http://' . $self->apache->hostname . $self->ctx->{opac_root} . "/home";
if($e->authtoken($self->cgi->cookie('ses'))) {
if($e->checkauth) {
- $self->apache->log->warn("authtime = " . $e->authtime);
-
$ctx->{authtoken} = $e->authtoken;
$ctx->{authtime} = $e->authtime;
$ctx->{user} = $e->requestor;
sub load_logout {
my $self = shift;
- my $url = 'http://' . $self->apache->hostname . $self->ctx->{opac_root} . "/home";
-
$self->apache->print(
$self->cgi->redirect(
- -url => $url,
+ -url => $self->ctx->{home_page},
-cookie => $self->cgi->cookie(
-name => 'ses',
-path => '/',
<html xmlns='http://www.w3.org/1999/xhtml' lang='[% ctx.locale %]' xml:lang='[% ctx.locale %]'>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
+ [% IF ctx.authtime %]
+ <meta http-equiv="refresh" content="[% ctx.authtime %];[% ctx.home_page %]">
+ [% END %]
<link rel="stylesheet" type="text/css"
href="[% ctx.media_prefix %]/css/skin/default/opac/semiauto.css" />
<link rel="stylesheet" type="text/css"