* extended last fix from Robin to the "MySQL runtime information" and "MySQL system variables" links;

* but allowed these directives to be bypassed for super-users
This commit is contained in:
Loïc Chapeaux
2001-11-09 07:54:05 +00:00
parent b02176e381
commit 476ef78631
6 changed files with 72 additions and 25 deletions

View File

@@ -5,14 +5,21 @@ phpMyAdmin - Changelog
$Id$
$Source$
2001-11-09 Lo<4C>c Chapeaux <lolo@phpheaven.net>
* config.inc.php3; Documentation.html; main.php3; phpinfo.php3;
libraries/common.lib.php3:
- extended last fix from Robin to the "MySQL runtime information" and
"MySQL system variables" links;
- but allowed these directives to be bypassed for super-users.
2001-11-08 Robin Johnson <robbat2@users.sourceforge.net>
* config.inc.php3,main.php3,phpinfo.php3: fixed bug #479303
- $cfgShowPHPInfo added, false by default
* config.inc.php3; main.php3; phpinfo.php3: fixed bug #479303
- $cfgShowPHPInfo added, false by default.
2001-11-07 Marc Delisle <lem9@users.sourceforge.net>
* tbl_select.php3, lang/some files: modify $strLimitNumRows
* tbl_select.php3, lang/some files: modify $strLimitNumRows.
* user_details.php3, lang/some files: modify $strRevokeGrantMessage
and $strRevokeMessage
and $strRevokeMessage.
2001-11-06 Lo<4C>c Chapeaux <lolo@phpheaven.net>
* db_details.php3, line 305; db_printview.php3, line 207: fixed bug #478592

View File

@@ -562,6 +562,18 @@
<br /><br />
</dd>
<dt>
<b>$cfgShowMysqlInfo </b>boolean<br />
<b>$cfgShowMysqlVars </b>boolean<br />
<b>$cfgShowPhpInfo </b>boolean
</dt>
<dd>
Defines whether to display the &quot;MySQL runtime information&quot;,
&quot;MySQL system variables&quot; and &quot;PHP information&quot;
links or not for simple users at the starting main (right) frame.
<br /><br />
</dd>
<dt><b>$cfgShowStats </b>boolean</dt>
<dd>
Defines whether to display space usage and statistics about databases
@@ -1055,15 +1067,16 @@
<p>
<b>I want to translate the messages to a new language or upgrade an
existing language, where do I start? </b>
existing language, where do I start?</b>
<br />
Always use the current cvs version of your language file.
For a new language, start from english.inc.php3. If you don't know
how to get the cvs version, please ask one of the developers. It would be
a good idea to subscribe to the phpmyadmin-translators discussion list,
how to get the cvs version, please ask one of the developers. It would be a
good idea to subscribe to the phpmyadmin-translators discussion list,
because this is where we ask for translations of new messages. You can
then send your translations to the sourceforge.net translation tracker.
</p>
<p>
<b>My Apache server crashes when using phpMyAdmin.</b>
<br />

View File

@@ -101,11 +101,16 @@ $cfgSkipLockedTables = FALSE; // mark used tables, make possible to show
$cfgShowSQL = TRUE; // show SQL queries as run
$cfgAllowUserDropDatabase = FALSE; // show a 'Drop database' link to normal users
$cfgConfirm = TRUE; // confirm 'DROP TABLE' & 'DROP DATABASE'
$cfgShowStats = TRUE; // allow to display statistics and space usage in
// the pages about database details and table
// properties
$cfgShowTooltip = TRUE; // display table comment as tooltip in left frame
$cfgShowPHPInfo = FALSE; // disable access to the phpinfo() call
// In the main frame, at startup...
$cfgShowMysqlInfo = FALSE; // whether to display the "MySQL runtime
$cfgShowMysqlVars = FALSE; // information", "MySQL system variables" and "PHP
$cfgShowPhpInfo = FALSE; // information" links for simple users or not
// In browse mode...
$cfgShowBlob = FALSE; // display blob field contents

View File

@@ -109,6 +109,15 @@ if (!defined('__LIB_COMMON__')){
if (!isset($cfgShowTooltip)) {
$cfgShowTooltip = TRUE;
}
if (!isset($cfgShowMysqlInfo)) {
$cfgShowMysqlInfo = FALSE;
}
if (!isset($cfgShowMysqlVars)) {
$cfgShowMysqlVars = FALSE;
}
if (!isset($cfgShowPhpInfo)) {
$cfgShowPhpInfo = FALSE;
}
if (!isset($cfgShowAll)) {
$cfgShowAll = FALSE;
}

View File

@@ -146,8 +146,8 @@ if ($server == 0 || count($cfgServers) > 1) {
/**
* Displays the mysql server related links
*/
if ($server > 0)
{
$is_superuser = FALSE;
if ($server > 0) {
?>
<!-- MySQL server related links -->
<td valign="top" align="left">
@@ -228,6 +228,10 @@ if ($server > 0)
// Server related links
?>
<!-- server-related links -->
<?php
if ($is_superuser || $cfgShowMysqlInfo) {
echo "\n";
?>
<tr>
<td valign="baseline"><img src="images/item.gif" width="7" height="7" alt="item" /></td>
<td>
@@ -236,6 +240,11 @@ if ($server > 0)
<?php echo show_docu('manual_Reference.html#SHOW') . "\n"; ?>
</td>
</tr>
<?php
} // end if
if ($is_superuser || $cfgShowMysqlVars) {
echo "\n";
?>
<tr>
<td valign="baseline"><img src="images/item.gif" width="7" height="7" alt="item" /></td>
<td>
@@ -245,6 +254,7 @@ if ($server > 0)
</td>
</tr>
<?php
}
echo "\n";
if ($is_process_priv) {
@@ -258,7 +268,7 @@ if ($server > 0)
</td>
</tr>
<?php
}
} // end if
echo "\n";
if ($is_reload_priv) {
@@ -400,9 +410,8 @@ echo "\n";
</tr>
<?php
if($cfgShowPHPInfo)
{ ?>
if ($is_superuser || $cfgShowPhpInfo) {
?>
<!-- PHP Information -->
<tr>
<td valign="baseline"><img src="images/item.gif" width="7" height="7" alt="item" /></td>
@@ -410,9 +419,11 @@ if($cfgShowPHPInfo)
<a href="phpinfo.php3" target="_new"><?php echo $strShowPHPInfo; ?></a>
</td>
</tr>
<?php
<?php
}
echo "\n";
?>
<!-- phpMyAdmin related urls -->
<tr>
<td valign="baseline"><img src="images/item.gif" width="7" height="7" alt="item" /></td>

View File

@@ -12,6 +12,8 @@ require('./libraries/common.lib.php3');
/**
* Displays PHP information
*/
if($cfgShowPHPInfo)
$is_superuser = @mysql_query('USE mysql', $userlink);
if ($is_superuser || $cfgShowPhpInfo) {
phpinfo();
}
?>