diff --git a/db_details_export.php3 b/db_details_export.php3 index edf38c56f..8446d8b3f 100644 --- a/db_details_export.php3 +++ b/db_details_export.php3 @@ -27,9 +27,14 @@ if ($num_tables > 1) { $multi_tables .= "\n"; $i = 0; - $is_selected = (!empty($selectall) ? ' selected="selected"' : ''); while ($i < $num_tables) { - $table = htmlspecialchars((PMA_MYSQL_INT_VERSION >= 32303) ? $tables[$i]['Name'] : $tables[$i]); + $table = (PMA_MYSQL_INT_VERSION >= 32303) ? $tables[$i]['Name'] : $tables[$i]; + if (!empty($selectall) || (isset($tmp_select) && strpos(' ' . $tmp_select, '|' . $table . '|'))) { + $is_selected = ' selected="selected"'; + } else { + $is_selected = ''; + } + $table = htmlspecialchars($table); $multi_tables .= ' ' . "\n"; $i++; } // end while