Do not pass default query to sql.php as it is not needed right now.

This commit is contained in:
Michal Čihař
2005-11-23 21:43:01 +00:00
parent 3f2e3ab766
commit 19f21606d3
4 changed files with 5 additions and 11 deletions

View File

@@ -76,6 +76,8 @@ $Source$
#1165206).
* config.default.php, sql.php, Documentation.html: Allow browse page to be
default (RFE #1228013).
* db_details_structure.php, left.php, tbl_properties_links.php: Do not
pass default query to sql.php as it is not needed right now.
2005-11-22 Sebastian Mendel <cybot_tm@users.sourceforge.net>
* added test/theme.php: for testing themes

View File

@@ -179,12 +179,8 @@ foreach ( $tables as $keyname => $each_table ) {
}
if ( $each_table['TABLE_ROWS'] > 0 ) {
$book_sql_query = PMA_queryBookmarks($db, $cfg['Bookmark'], '\'' . PMA_sqlAddslashes($each_table['TABLE_NAME']) . '\'', 'label');
$browse_table = '<a href="sql.php?' . $tbl_url_query . '&amp;sql_query='
. ( $book_sql_query ? urlencode($book_sql_query) : urlencode('SELECT * FROM ' . PMA_backquote($each_table['TABLE_NAME'])))
. '&amp;pos=0">' . $titles['Browse'] . '</a>';
$search_table = '<a href="tbl_select.php?' . $tbl_url_query . '">'
. $titles['Search'] . '</a>';
$browse_table = '<a href="sql.php?' . $tbl_url_query . '&amp;pos=0">' . $titles['Browse'] . '</a>';
$search_table = '<a href="tbl_select.php?' . $tbl_url_query . '">' . $titles['Search'] . '</a>';
} else {
$browse_table = $titles['NoBrowse'];
$search_table = $titles['NoSearch'];

View File

@@ -470,9 +470,7 @@ function PMA_displayTableList( $tables, $visible = false,
.' href="sql.php?' . $GLOBALS['common_url_query']
.'&amp;table=' . urlencode( $table['Name'] )
.'&amp;goto=' . $GLOBALS['cfg']['DefaultTabTable']
.'&amp;sql_query=' . urlencode('SELECT * FROM `'
. $table['Name'] . '`') . '" '
.' >'
. '" >'
.'<img class="icon"';
if ( 'VIEW' === strtoupper( $table['Comment'] ) ) {
echo ' src="' . $GLOBALS['pmaThemeImage'] . 's_views.png"';

View File

@@ -12,7 +12,6 @@ PMA_checkParameters(array('db', 'table'));
* Prepares links
*/
require_once('./libraries/bookmark.lib.php');
$book_sql_query = PMA_queryBookmarks($db, $GLOBALS['cfg']['Bookmark'], '\'' . PMA_sqlAddslashes($table) . '\'', 'label');
/**
* Displays links
@@ -92,7 +91,6 @@ if ( ! (isset($db_is_information_schema) && $db_is_information_schema) ) {
if ($table_info_num_rows > 0 || $tbl_is_view) {
$tabs['browse']['link'] = 'sql.php';
$tabs['browse']['args']['sql_query'] = isset($book_sql_query) && $book_sql_query != FALSE ? $book_sql_query : 'SELECT * FROM ' . PMA_backquote($table);
$tabs['browse']['args']['pos'] = 0;
$tabs['search']['link'] = 'tbl_select.php';
}