From 4af5042b1a017c7e66c8f171fd4e331dff5b4d3e Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Wed, 21 Jun 2006 12:33:08 +0000 Subject: [PATCH] bug #1504662, server message for http auth_type --- libraries/auth/http.auth.lib.php | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/libraries/auth/http.auth.lib.php b/libraries/auth/http.auth.lib.php index 7fe0ac43f..601040f06 100644 --- a/libraries/auth/http.auth.lib.php +++ b/libraries/auth/http.auth.lib.php @@ -188,9 +188,23 @@ function PMA_auth_set_user() */ function PMA_auth_fails() { - PMA_auth(); + if (PMA_DBI_getError() && $GLOBALS['errno'] != 1045) { + $conn_error = PMA_sanitize(PMA_DBI_getError()); + header('Content-Type: text/html; charset=' . $GLOBALS['charset']); + $page_title = 'phpMyAdmin ' . PMA_VERSION; + require './libraries/header_meta_style.inc.php'; + + echo '

' . $GLOBALS['strError'] . '

' . "\n"; + echo $conn_error . '
' . "\n"; + // no footer here, would not make sense + echo '' . "\n"; + // exit immediately to avoid warnings from the db library + exit; + } else { + PMA_auth(); + return true; + } - return true; } // end of the 'PMA_auth_fails()' function ?>