improved compatibility with the old phpMyAdmin configuration file

This commit is contained in:
Loïc Chapeaux
2001-10-17 10:11:40 +00:00
parent 47d76c1ef9
commit 0f1f461f4b
2 changed files with 34 additions and 5 deletions

View File

@@ -9,6 +9,8 @@ $Source$
* Documentation.html, lines 766-770: added a link to the official MySQL * Documentation.html, lines 766-770: added a link to the official MySQL
documentation for the "socket error" problems. documentation for the "socket error" problems.
* index.php3, line 53; lang/*: out-sourced the "no frame" sentence. * index.php3, line 53; lang/*: out-sourced the "no frame" sentence.
* libraries/common.lib.php3: improved compatibility with the old phpMyAdmin
configuration file.
2001-10-16 Lo<4C>c Chapeaux <lolo@phpheaven.net> 2001-10-16 Lo<4C>c Chapeaux <lolo@phpheaven.net>
* lang/*: cleanup thanks to Bj<42>rn T. Hallberg - Removed unused strings * lang/*: cleanup thanks to Bj<42>rn T. Hallberg - Removed unused strings

View File

@@ -55,9 +55,6 @@ if (!defined('__LIB_COMMON__')){
if (!isset($pos)) { if (!isset($pos)) {
$pos = 0; $pos = 0;
} }
if (!isset($cfgProtectBinary)) {
$cfgProtectBinary = FALSE;
}
/** /**
@@ -101,20 +98,50 @@ if (!defined('__LIB_COMMON__')){
* versions of phpMyAdmin/php/mysql... * versions of phpMyAdmin/php/mysql...
*/ */
include('./config.inc.php3'); include('./config.inc.php3');
// For compatibility with old config.inc.php3 // For compatibility with old config.inc.php3
if (!isset($cfgShowStats)) {
$cfgShowStats = TRUE;
}
if (!isset($cfgShowTooltip)) {
$cfgShowTooltip = TRUE;
}
if (!isset($cfgShowAll)) {
$cfgShowAll = FALSE;
}
if (!isset($cfgProtectBinary)) {
if (isset($cfgProtectBlob)) {
$cfgProtectBinary = ($cfgProtectBlob ? 'blob' : FALSE);
unset($cfgProtectBlob);
} else {
$cfgProtectBinary = 'blob';
}
}
if (!isset($cfgZipDump)) {
$cfgZipDump = (isset($cfgGZipDump) ? $cfgGZipDump : TRUE);
}
if (!isset($cfgLeftBgColor)) {
$cfgLeftBgColor = '#D0DCE0';
}
if (!isset($cfgRightBgColor)) {
$cfgRightBgColor = '#F5F5F5';
}
if (!isset($cfgTextareaCols)) { if (!isset($cfgTextareaCols)) {
$cfgTextareaCols = 40; $cfgTextareaCols = 40;
} }
if (!isset($cfgTextareaRows)) { if (!isset($cfgTextareaRows)) {
$cfgTextareaRows = 7; $cfgTextareaRows = 7;
} }
// Adds a trailing slash et the end of the phpMyAdmin uri if it does not // Adds a trailing slash et the end of the phpMyAdmin uri if it does not
// exist // exist
if ($cfgPmaAbsoluteUri != '' && substr($cfgPmaAbsoluteUri, -1) != '/') { if ($cfgPmaAbsoluteUri != '' && substr($cfgPmaAbsoluteUri, -1) != '/') {
$cfgPmaAbsoluteUri .= '/'; $cfgPmaAbsoluteUri .= '/';
} }
// Gets some constants // Gets some constants
include('./libraries/defines.lib.php3'); include('./libraries/defines.lib.php3');
// If zlib output compression is set in the php configuration file, no // If zlib output compression is set in the php configuration file, no
// output buffering should be run // output buffering should be run
if (PHP_INT_VERSION < 40000 if (PHP_INT_VERSION < 40000