diff --git a/include/functions_html.inc.php b/include/functions_html.inc.php index a41b87090..be27f8ce6 100644 --- a/include/functions_html.inc.php +++ b/include/functions_html.inc.php @@ -261,35 +261,23 @@ function access_denied() { global $user, $conf; - $login_url = - get_root_url().'identification.php?redirect=' - .urlencode(urlencode($_SERVER['REQUEST_URI'])); - - $access_denied_html = - ''. - ''. - '
'. - '
'. - 'warning-triangle'. - '

'.l10n('You are not authorized to access the requested page').'

'; - if ( isset($user) and !is_a_guest() ) { set_status_header(401); - echo $access_denied_html; - echo ''.l10n('Home').'
'; - echo str_repeat( ' ', 512); //IE6 doesn't error output if below a size + echo ' + +
+
+ warning-triangle +

'.l10n('You are not authorized to access the requested page').'

+ '.l10n('Home').' +
+
'; exit(); } - elseif (!$conf['guest_access'] and is_a_guest()) - { - redirect_http($login_url); - } - else - { - redirect_html($login_url); - } + + redirect_http(get_root_url().'identification.php?redirect='.urlencode(urlencode($_SERVER['REQUEST_URI']))); }