diff --git a/ChangeLog b/ChangeLog index f8a9ea37a..05ed93713 100755 --- a/ChangeLog +++ b/ChangeLog @@ -9,6 +9,11 @@ $Source$ * libraries/sqlparser.lib.php3 - Confirmation is also needed on TRUNCATE statements! * libraries/common.lib.php3 - RFE #758051 (simpler PHPcode generation) + * config.inc.php3, db_details_structure.php3, libraries/common.lib.php3, + libraries/config_import.lib.php3: *EXPERIMENTAL* - implemented buttons + for the database properties page and implemented RFE #752062: multi- + column display for many tables. + (thanks to Kawika Ohumukini [boogie33]). 2003-07-24 Marc Delisle * libraries/sqlparser.lib.php3 /relation.lib.php3 /get_foreign.lib.php3: diff --git a/config.inc.php3 b/config.inc.php3 index cd475be34..dec75361c 100755 --- a/config.inc.php3 +++ b/config.inc.php3 @@ -36,7 +36,7 @@ if (!isset($old_error_reporting)) { * If the auto-detection code does work properly, you can set to TRUE the * $cfg['PmaAbsoluteUri_DisableWarning'] variable below. */ -$cfg['PmaAbsoluteUri'] = 'http://www.garvinhicking.de/cvs/phpMyAdmin/'; +$cfg['PmaAbsoluteUri'] = ''; /** @@ -76,12 +76,9 @@ $cfg['Servers'][$i]['controluser'] = ''; // MySQL control user settin // (this user must have read-only $cfg['Servers'][$i]['controlpass'] = ''; // access to the "mysql/user" // and "mysql/db" tables) -$cfg['Servers'][$i]['auth_type'] = 'http'; // Authentication method (config, http or cookie based)? -$cfg['Servers'][$i]['blowfish_secret'] = 'hammer'; // Secret key used by - // blowfish encryption - // (if auth_type='cookie') -$cfg['Servers'][$i]['user'] = 'superdbl'; // MySQL user -$cfg['Servers'][$i]['password'] = 'geheim00'; // MySQL password (only needed +$cfg['Servers'][$i]['auth_type'] = 'config'; // Authentication method (config, http or cookie based)? +$cfg['Servers'][$i]['user'] = 'root'; // MySQL user +$cfg['Servers'][$i]['password'] = ''; // MySQL password (only needed // with 'config' auth_type) $cfg['Servers'][$i]['only_db'] = ''; // If set to a db-name, only // this db is displayed @@ -231,7 +228,7 @@ $cfg['SuggestDBName'] = TRUE; // suggest a new DB name if possible (fa // In browse mode... $cfg['ShowBlob'] = FALSE; // display blob field contents $cfg['NavigationBarIconic'] = TRUE; // do not display text inside navigation bar buttons -$cfg['ShowAll'] = TRUE; // allows to display all the rows +$cfg['ShowAll'] = FALSE; // allows to display all the rows $cfg['MaxRows'] = 30; // maximum number of rows to display $cfg['Order'] = 'ASC'; // default for 'ORDER BY' clause (valid // values are 'ASC', 'DESC' or 'SMART' -ie @@ -258,6 +255,10 @@ $cfg['BZipDump'] = TRUE; // dump files // Tabs display settings $cfg['LightTabs'] = FALSE; // use graphically less intense menu tabs +$cfg['PropertiesIconic'] = TRUE; // Use icons instead of text for the table display of a database +$cfg['PropertiesNumColumns'] = 1; // How many columns should be used for table display of a database? + // (a value larger than 1 results in some information being hidden) + $cfg['DefaultTabServer'] = 'main.php3'; // Possible values: // 'main.php3' = the welcome page diff --git a/db_details_structure.php3 b/db_details_structure.php3 index da15ce595..0ae253735 100644 --- a/db_details_structure.php3 +++ b/db_details_structure.php3 @@ -39,6 +39,32 @@ if (empty($is_info)) { } } +// Display function +function pma_TableHeader() { +?> + + + + + + + 1)) { + ?> + + + ' . $GLOBALS['strSize'] . ''; + } + echo "\n"; + ?> + += 32303) { -
  
- - - - - - - ' . $strSize . ''; + 1) { +?> +
  
+ + - 1 ? (ceil($num_tables / $cfg['PropertiesNumColumns']) + 1) : 0); + $row_count = 0; while (list($keyname, $sts_data) = each($tables)) { $table = $sts_data['Name']; $table_encoded = urlencode($table); @@ -146,52 +170,90 @@ else if (PMA_MYSQL_INT_VERSION >= 32303) { $tbl_url_query = $url_query . '&table=' . $table_encoded; $bgcolor = ($i++ % 2) ? $cfg['BgcolorOne'] : $cfg['BgcolorTwo']; echo "\n"; + + $row_count++; + if($num_columns > 0 && $num_tables > $num_columns && (($row_count % ($num_columns)) == 0)) { + $bgcolor = $cfg['BgcolorTwo']; + $row_count = 1; ?> - - +
+ -
- /> +
- -     - - + + + + + + /> + + +     + + '; + $titles['Select'] = '' . $strSelect . ''; + $titles['NoBrowse'] = '' . $strBrowse . ''; + $titles['NoSelect'] = '' . $strSelect . ''; + $titles['Insert'] = '' . $strInsert . ''; + $titles['Properties'] = '' . $strProperties . ''; + $titles['Drop'] = '' . $strDrop . ''; + $titles['Empty'] = '' . $strEmpty . ''; + $titles['NoEmpty'] = '' . $strEmpty . ''; + } else { + $titles['Browse'] = $strBrowse; + $titles['Select'] = $strSelect; + $titles['NoBrowse'] = $strBrowse; + $titles['NoSelect'] = $strSelect; + $titles['Insert'] = $strInsert; + $titles['Properties'] = $strProperties; + $titles['Drop'] = $strDrop; + $titles['Empty'] = $strEmpty; + $titles['NoEmpty'] = $strEmpty; + } + if (!empty($sts_data['Rows'])) { echo '' . $strBrowse . ''; + . '&pos=0">' . $titles['Browse'] . ''; } else { - echo $strBrowse; + echo $titles['NoBrowse']; } ?> - - + + ' - . $strSelect . ''; + . $titles['Select'] . ''; } else { - echo $strSelect; + echo $titles['NoSelect']; } ?> - - + + - - - + + + - - - + + + - - - + + + = 32303) { . urlencode(sprintf($strTableHasBeenEmptied, htmlspecialchars($table))) . '" onclick="return confirmLink(this, \'DELETE FROM '; } - echo PMA_jsFormat($table) . '\')">' . $strEmpty . ''; + echo PMA_jsFormat($table) . '\')">' . $titles['Empty'] . ''; } else { - echo $strEmpty; + echo $titles['NoEmpty']; } ?> - + = 32303) { $display_rows = 'unknown'; } ?> - + - - -    - + 1)) { + ?> + +    + + - -    - - + +    + + - - - + + + - + = 32303) { } echo "\n"; ?> - - - -    - - - - - - - - - -- - + + + +    + + + + + + + 1)) { + ?> + + -- + + - -   - - + +   + + - + - - - <?php echo $strWithChecked; ?> - - -  /  - - -     - - ' @@ -375,19 +447,27 @@ else if (PMA_MYSQL_INT_VERSION >= 32303) { echo ' ' . "\n"; ?> - - - - - + + + + + + + 1) { +?> + + - + = 3.23.03 diff --git a/libraries/common.lib.php3 b/libraries/common.lib.php3 index c985bd7bc..d861cb73f 100644 --- a/libraries/common.lib.php3 +++ b/libraries/common.lib.php3 @@ -135,7 +135,7 @@ h1 {font-family: sans-serif; font-size: large; font-weight: bold} * Includes compatibility code for older config.inc.php3 revisions * if necessary */ - if (!isset($cfg['FileRevision']) || (int) substr($cfg['FileRevision'], 13, 3) < 190) { + if (!isset($cfg['FileRevision']) || (int) substr($cfg['FileRevision'], 13, 3) < 195) { include('./libraries/config_import.lib.php3'); } diff --git a/libraries/config_import.lib.php3 b/libraries/config_import.lib.php3 index cc11123b3..1d64f9806 100644 --- a/libraries/config_import.lib.php3 +++ b/libraries/config_import.lib.php3 @@ -297,7 +297,15 @@ if (!defined('PMA_CONFIG_IMPORT_LIB_INCLUDED')) { if (!isset($cfg['LightTabs'])) { $cfg['LightTabs'] = FALSE; } + + if (!isset($cfg['PropertiesIconic'])) { + $cfg['PropertiesIconic'] = TRUE; + } + if (!isset($cfg['PropertiesNumColumns'])) { + $cfg['PropertiesNumColumns'] = 1; + } + if (!isset($cfg['ShowTooltip'])) { if (isset($cfgShowTooltip)) { $cfg['ShowTooltip'] = $cfgShowTooltip;