feature #458452 (display the logged in user)
This commit is contained in:
11
main.php3
11
main.php3
@@ -44,18 +44,17 @@ echo "\n";
|
|||||||
<?php
|
<?php
|
||||||
// Don't display server info if $server == 0 (no server selected)
|
// Don't display server info if $server == 0 (no server selected)
|
||||||
if ($server > 0) {
|
if ($server > 0) {
|
||||||
$local_query = 'SELECT Version() as version';
|
$local_query = 'SELECT VERSION() as version, USER() as user';
|
||||||
$res_version = mysql_query($local_query) or mysql_die('', $local_query, FALSE, FALSE);
|
$res = mysql_query($local_query) or mysql_die('', $local_query, FALSE, FALSE);
|
||||||
$row_version = mysql_fetch_array($res_version);
|
echo '<p><b>MySQL ' . mysql_result($res, 0, 'version') . ' ' . $strRunning . ' ' . $cfgServer['host'];
|
||||||
echo '<p><b>MySQL ' . $row_version['version'] . ' ' . $strRunning . ' ' . $cfgServer['host'];
|
|
||||||
if (!empty($cfgServer['port'])) {
|
if (!empty($cfgServer['port'])) {
|
||||||
echo ':' . $cfgServer['port'];
|
echo ':' . $cfgServer['port'];
|
||||||
}
|
}
|
||||||
if (!empty($cfgServer['socket'])) {
|
if (!empty($cfgServer['socket'])) {
|
||||||
echo ':' . $cfgServer['socket'];
|
echo ':' . $cfgServer['socket'];
|
||||||
}
|
}
|
||||||
echo "</b></p><br />\n";
|
echo ' ' . $strRunningAs . ' ' . mysql_result($res, 0, 'user') . '</b></p><br />' . "\n";
|
||||||
}
|
} // end if
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Reference in New Issue
Block a user