Bugfix in errors/*.pl and opac/errors/*.pl
The scripts did not define the status printed on the first line of HTTP headers correctly: they were sending 200 OK, which was confusing for browsers. Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
This commit is contained in:
parent
f7d019dcec
commit
de94e449cd
|
|
@ -34,4 +34,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '400 Bad Request';
|
||||
|
|
|
|||
|
|
@ -34,4 +34,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '401 Unauthorized';
|
||||
|
|
|
|||
|
|
@ -34,4 +34,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '402 Payment Required';
|
||||
|
|
|
|||
|
|
@ -34,4 +34,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '403 Forbidden';
|
||||
|
|
|
|||
|
|
@ -34,4 +34,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '404 Not Found';
|
||||
|
|
|
|||
|
|
@ -34,4 +34,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '500 Internal Server Error';
|
||||
|
|
|
|||
|
|
@ -36,4 +36,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '400 Bad Request';
|
||||
|
|
|
|||
|
|
@ -36,4 +36,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '401 Unauthorized';
|
||||
|
|
|
|||
|
|
@ -36,4 +36,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '402 Payment Required';
|
||||
|
|
|
|||
|
|
@ -36,4 +36,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '403 Forbidden';
|
||||
|
|
|
|||
|
|
@ -36,4 +36,4 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
|
|||
}
|
||||
);
|
||||
$template->param( admin => $admin );
|
||||
output_html_with_http_headers $query, $cookie, $template->output;
|
||||
output_with_http_headers $query, $cookie, $template->output, 'html', '500 Internal Server Error';
|
||||
|
|
|
|||
Loading…
Reference in New Issue