diff options
author | Alexander M. Turek <me@derrabus.de> | 2005-04-01 02:28:04 +0400 |
---|---|---|
committer | Alexander M. Turek <me@derrabus.de> | 2005-04-01 02:28:04 +0400 |
commit | 0cddbb2cd42e38c0b28cb2757f3fa4b2ab332455 (patch) | |
tree | 7a775ee72e0be6ef38b90a2175bc076912f8e4b1 | |
parent | 8ddcb6d302cd67140953fde166378240af2600e3 (diff) |
bug #1174045
-rwxr-xr-x | ChangeLog | 3 | ||||
-rw-r--r-- | left.php | 12 |
2 files changed, 13 insertions, 2 deletions
@@ -5,6 +5,9 @@ phpMyAdmin - Changelog $Id$ $Source$ +2005-03-31 Alexander M. Turek <me@derrabus.de> + * left.php: Undefined offset (Bug #1174045). + 2005-03-31 Marc Delisle <lem9@users.sourceforge.net> * Documentation.html: added FAQ 5.17 about problem with Firefox when the Tabbrowser Extensions plugin is installed @@ -451,6 +451,14 @@ if ($num_dbs > 1) { if (!empty($db_start) && $db == $db_start) { $selected_db = $j; } + /** + * The query below will return a result set with a single field under + * MySQL versions before 5.0 and one with two fields under MySQL 5.0 + * and above. The MySQL 5 result set also includes the table type + * ('BASE TABLE', 'VIEW' or 'TEMPORARY'). + * MySQL 4 does neither know about views nor differ between permanent + * and temporary tables, so the table type is irrelevant here. + */ $tables = PMA_DBI_try_query('SHOW ' . (PMA_MYSQL_INT_VERSION >= 50000 ? 'FULL ' : '') . 'TABLES FROM ' . PMA_backquote($db) . ';', NULL, PMA_DBI_QUERY_STORE); $num_tables = ($tables) ? @PMA_DBI_num_rows($tables) : 0; $common_url_query = PMA_generate_common_url($db); @@ -518,7 +526,7 @@ if ($num_dbs > 1) { $tablestack = array(); $table_array = array(); $table_types = array(); - while (list($table, $type) = PMA_DBI_fetch_row($tables)) { + while (@list($table, $type) = PMA_DBI_fetch_row($tables)) { $table_item = (!empty($tooltip_name) && isset($tooltip_name[$table]) && !empty($tooltip_name[$table]) && $cfg['ShowTooltipAliasTB'] && strtolower($cfg['ShowTooltipAliasTB']) !== 'nested' ? htmlspecialchars($tooltip_name[$table]) : htmlspecialchars($table)); @@ -596,7 +604,7 @@ if ($num_dbs > 1) { $table_array = array(); // Gets the list of tables from the current database $book_sql_cache = PMA_queryDBBookmarks($db, $cfg['Bookmark'], $table_array); - while (list($table, $type) = PMA_DBI_fetch_row($tables)) { + while (@list($table, $type) = PMA_DBI_fetch_row($tables)) { $table_array[$table] = ''; $url_title = (!empty($tooltip) && isset($tooltip[$table])) ? htmlspecialchars($tooltip[$table]) |