From 73dc66c0a1c4f998df7af511c28f04ae45533ff2 Mon Sep 17 00:00:00 2001 From: thilinaa Date: Sun, 19 Aug 2012 10:46:32 +0530 Subject: [PATCH] modifications for some global variabes --- libraries/server_privileges.lib.php | 34 ++++++++++++++--------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/libraries/server_privileges.lib.php b/libraries/server_privileges.lib.php index 0a9be05db2..d9dc3cf9ff 100644 --- a/libraries/server_privileges.lib.php +++ b/libraries/server_privileges.lib.php @@ -2841,40 +2841,40 @@ function PMA_getAddUserHtmlFieldset($conditional_class) * @return string $html_output */ function PMA_getHtmlHeaderForDisplayUserProperties( - $dbname_is_wildcard, $url_dbname + $dbname_is_wildcard, $url_dbname, $dbname, $username, $hostname, $tablename ) { $html_output = '

' . "\n" . PMA_CommonFunctions::getInstance()->getIcon('b_usredit.png') . __('Edit Privileges') . ': ' . __('User'); - if (isset($_REQUEST['dbname'])) { + if (isset($dbname)) { $html_output .= ' \'' . htmlspecialchars($_REQUEST['username']) - . '\'@\'' . htmlspecialchars($_REQUEST['hostname']) + . '&username=' . htmlspecialchars(urlencode($username)) + . '&hostname=' . htmlspecialchars(urlencode($hostname)) + . '&dbname=&tablename=">\'' . htmlspecialchars($username) + . '\'@\'' . htmlspecialchars($hostname) . '\'' . "\n"; $html_output .= ' - ' . ($dbname_is_wildcard ? __('Databases') : __('Database') ); if (isset($_REQUEST['tablename'])) { $html_output .= ' ' . htmlspecialchars($_REQUEST['dbname']) + . '&tablename=">' . htmlspecialchars($dbname) . ''; $html_output .= ' - ' . __('Table') - . ' ' . htmlspecialchars($_REQUEST['tablename']) . ''; + . ' ' . htmlspecialchars($tablename) . ''; } else { - $html_output .= ' ' . htmlspecialchars($_REQUEST['dbname']) . ''; + $html_output .= ' ' . htmlspecialchars($dbname) . ''; } } else { - $html_output .= ' \'' . htmlspecialchars($_REQUEST['username']) - . '\'@\'' . htmlspecialchars($_REQUEST['hostname']) + $html_output .= ' \'' . htmlspecialchars($username) + . '\'@\'' . htmlspecialchars($hostname) . '\'' . "\n"; } @@ -3009,7 +3009,7 @@ function PMA_getHtmlForDisplayUserProperties($dbname_is_wildcard,$url_dbname, $common_functions = PMA_CommonFunctions::getInstance(); $html_output = PMA_getHtmlHeaderForDisplayUserProperties( - $dbname_is_wildcard, $url_dbname + $dbname_is_wildcard, $url_dbname, $dbname, $username, $hostname, $tablename ); $sql = "SELECT '1' FROM `mysql`.`user`" @@ -3020,10 +3020,10 @@ function PMA_getHtmlForDisplayUserProperties($dbname_is_wildcard,$url_dbname, if ($user_does_not_exists) { $html_output .= PMA_Message::error( - __('The selected user was not found in the privilege table.') - )->getDisplay(); + __('The selected user was not found in the privilege table.') + )->getDisplay(); $html_output .= PMA_getHtmlForDisplayLoginInformationFields(); - //exit; + //exit; } $html_output .= '