patch #1821154, HTTP authentication: fix auth working with php/mod_fastcgi

This commit is contained in:
Marc Delisle
2007-11-01 20:59:48 +00:00
parent 3bb64c78ea
commit d12c01fd59
2 changed files with 5 additions and 1 deletions

View File

@@ -36,7 +36,9 @@ function PMA_auth() {
$server_message = preg_replace('/[^\x20-\x7e]/i', '', $server_message);
header('WWW-Authenticate: Basic realm="phpMyAdmin ' . $server_message . '"');
header('HTTP/1.0 401 Unauthorized');
header('status: 401 Unauthorized');
if (php_sapi_name() !== 'cgi-fcgi') {
header('status: 401 Unauthorized');
}
// Defines the charset to be used
header('Content-Type: text/html; charset=' . $GLOBALS['charset']);