diff --git a/ChangeLog b/ChangeLog index d43ea84ac..cf5121d7b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,9 @@ phpMyAdmin - ChangeLog $Id$ $HeadURL$ +2007-03-02 Marc Delisle + * server_status.php: use PMA_getenv('PHP_SELF'), thanks to Sebastian + 2007-03-02 Sebastian Mendel * libraries/common.lib.php: bug #1672379 Call to undefined function PMA_removeCookie() diff --git a/server_status.php b/server_status.php index d11e1db48..07cdf156a 100644 --- a/server_status.php +++ b/server_status.php @@ -262,8 +262,11 @@ $sections = array( // variable or section name => (name => url) $links = array(); +// because of PMA_NO_VARIABLES_IMPORT, the $PHP_SELF globalized by +// grab_globals is not available here when register_globals = Off +// and in some situations, $_SERVER['PHP_SELF'] is not defined $links['table'][$strFlushTables] - = $_SERVER['PHP_SELF'] . '?flush=TABLES&' . PMA_generate_common_url(); + = PMA_getenv('PHP_SELF') . '?flush=TABLES&' . PMA_generate_common_url(); $links['table'][$strShowOpenTables] = 'sql.php?sql_query=' . urlencode('SHOW OPEN TABLES') . '&goto=server_status.php&' . PMA_generate_common_url(); @@ -278,7 +281,7 @@ $links['repl']['MySQL - ' . $strDocu] = $cfg['MySQLManualBase'] . '/replication.html'; $links['qcache'][$strFlushQueryCache] - = $_SERVER['PHP_SELF'] . '?flush=' . urlencode('QUERY CACHE') . '&' . + = PMA_getenv('PHP_SELF') . '?flush=' . urlencode('QUERY CACHE') . '&' . PMA_generate_common_url(); $links['qcache']['MySQL - ' . $strDocu] = $cfg['MySQLManualBase'] . '/query-cache.html'; @@ -337,10 +340,10 @@ $hour_factor = 3600 / $server_status['Uptime']; ?>