Rename db_* files to drop useless _details part.

This commit is contained in:
Michal Čihař
2006-10-25 12:25:01 +00:00
parent ad06b4a991
commit cac4247057
34 changed files with 93 additions and 91 deletions

View File

@@ -746,7 +746,7 @@ if (!defined('PMA_MINIMUM_COMMON')) {
if (isset($table)) {
$doedit_goto = '<a href="tbl_sql.php?' . PMA_generate_common_url($db, $table) . '&amp;sql_query=' . urlencode($the_query) . '&amp;show_query=1">';
} else {
$doedit_goto = '<a href="db_details.php?' . PMA_generate_common_url($db) . '&amp;sql_query=' . urlencode($the_query) . '&amp;show_query=1">';
$doedit_goto = '<a href="db_sql.php?' . PMA_generate_common_url($db) . '&amp;sql_query=' . urlencode($the_query) . '&amp;show_query=1">';
}
if ($GLOBALS['cfg']['PropertiesIconic']) {
echo $doedit_goto
@@ -1371,7 +1371,7 @@ window.parent.updateTableTitle('<?php echo $uni_tbl; ?>', '<?php echo PMA_jsForm
//if (!isset($GLOBALS['goto'])) {
//$edit_target = (isset($GLOBALS['table'])) ? $cfg['DefaultTabTable'] : $cfg['DefaultTabDatabase'];
$edit_target = isset($GLOBALS['db']) ? (isset($GLOBALS['table']) ? 'tbl_sql.php' : 'db_details.php') : 'server_sql.php';
$edit_target = isset($GLOBALS['db']) ? (isset($GLOBALS['table']) ? 'tbl_sql.php' : 'db_sql.php') : 'server_sql.php';
//} elseif ($GLOBALS['goto'] != 'main.php') {
// $edit_target = $GLOBALS['goto'];
//} else {
@@ -2574,11 +2574,11 @@ $goto_whitelist = array(
//'chk_rel.php',
'db_create.php',
'db_datadict.php',
'db_details.php',
'db_details_export.php',
'db_details_importdocsql.php',
'db_details_qbe.php',
'db_details_structure.php',
'db_sql.php',
'db_export.php',
'db_importdocsql.php',
'db_qbe.php',
'db_structure.php',
'db_import.php',
'db_operations.php',
'db_printview.php',

View File

@@ -161,7 +161,7 @@ $cfg['LeftFrameTableLevel'] = '1'; // How many sublevels should be display
// up tables by the above Separator
$cfg['ShowTooltip'] = TRUE; // display table comment as tooltip in left frame
$cfg['ShowTooltipAliasDB'] = FALSE; // if ShowToolTip is enabled, this defines that table/db comments
$cfg['ShowTooltipAliasTB'] = FALSE; // are shown (in the left menu and db_details_structure) instead of
$cfg['ShowTooltipAliasTB'] = FALSE; // are shown (in the left menu and db_structure) instead of
// table/db names. Setting ShowTooltipAliasTB to 'nested' will only
// use the Aliases for nested descriptors, not the table itself.
@@ -235,10 +235,10 @@ $cfg['DefaultTabServer'] = 'main.php';
// 'server_variables.php' = MySQL server variables
// 'server_privileges.php' = user management
// 'server_processlist.php' = process list
$cfg['DefaultTabDatabase'] = 'db_details_structure.php';
$cfg['DefaultTabDatabase'] = 'db_structure.php';
// Possible values:
// 'db_details_structure.php' = tables list
// 'db_details.php' = sql form
// 'db_structure.php' = tables list
// 'db_sql.php' = sql form
// 'db_search.php' = search query
// 'db_operations.php' = operations on database
$cfg['DefaultTabTable'] = 'tbl_structure.php';

View File

@@ -136,5 +136,5 @@ $num_tables = count( $tables );
/**
* Displays top menu links
*/
require('./libraries/db_details_links.inc.php');
require('./libraries/db_links.inc.php');
?>

View File

@@ -28,7 +28,7 @@ if (($is_superuser || $GLOBALS['cfg']['AllowUserDropDatabase']) && ! $db_is_info
$tab_drop['args']['sql_query'] = 'DROP DATABASE ' . PMA_backquote($db);
$tab_drop['args']['zero_rows'] = sprintf($GLOBALS['strDatabaseHasBeenDropped'], htmlspecialchars(PMA_backquote($db)));
$tab_drop['args']['goto'] = 'main.php';
$tab_drop['args']['back'] = 'db_details' . $sub_part . '.php';
$tab_drop['args']['back'] = 'db' . $sub_part . '.php';
$tab_drop['args']['reload'] = 1;
$tab_drop['args']['purge'] = 1;
$tab_drop['attr'] = 'onclick="return confirmLinkDropDB(this, \'DROP DATABASE ' . PMA_jsFormat($db) . '\')"';
@@ -38,16 +38,16 @@ if (($is_superuser || $GLOBALS['cfg']['AllowUserDropDatabase']) && ! $db_is_info
* export, search and qbe links if there is at least one table
*/
if ( $num_tables > 0 ) {
$tab_export['link'] = 'db_details_export.php';
$tab_export['link'] = 'db_export.php';
$tab_search['link'] = 'db_search.php';
$tab_qbe['link'] = 'db_details_qbe.php';
$tab_qbe['link'] = 'db_qbe.php';
}
$tab_structure['link'] = 'db_details_structure.php';
$tab_structure['link'] = 'db_structure.php';
$tab_structure['text'] = $GLOBALS['strStructure'];
$tab_structure['icon'] = 'b_props.png';
$tab_sql['link'] = 'db_details.php';
$tab_sql['link'] = 'db_sql.php';
$tab_sql['args']['db_query_force'] = 1;
$tab_sql['text'] = $GLOBALS['strSQL'];
$tab_sql['icon'] = 'b_sql.png';

View File

@@ -29,7 +29,7 @@ if (empty($is_db)) {
} // end if (ensures db exists)
if (empty($is_table) && !defined('PMA_SUBMIT_MULT')) {
// Not a valid table name -> back to the db_details.php
// Not a valid table name -> back to the db_sql.php
if (isset($table) && strlen($table)) {
$_result = PMA_DBI_try_query(
'SHOW TABLES LIKE \'' . PMA_sqlAddslashes($table, true) . '\';',
@@ -69,7 +69,7 @@ if (empty($is_table) && !defined('PMA_SUBMIT_MULT')) {
$url_params['display_query'] = $display_query;
}
PMA_sendHeaderLocation(
$cfg['PmaAbsoluteUri'] . 'db_details.php'
$cfg['PmaAbsoluteUri'] . 'db_sql.php'
. PMA_generate_common_url($url_params, '&'));
}
}

View File

@@ -131,7 +131,7 @@ if ( !empty($submit_mult) && !empty($what)) {
$url_query .= '&amp;goto=tbl_sql.php&amp;back=tbl_sql.php';
require('./libraries/tbl_info.inc.php');
} elseif (isset($db) && strlen($db)) {
require('./libraries/db_details_common.inc.php');
require('./libraries/db_common.inc.php');
require('./libraries/db_info.inc.php');
}
// Builds the query
@@ -229,7 +229,7 @@ if ( !empty($submit_mult) && !empty($what)) {
<form action="<?php echo $action; ?>" method="post">
<input type="hidden" name="query_type" value="<?php echo $what; ?>" />
<?php
if (strpos(' ' . $action, 'db_details') == 1) {
if (strpos(' ' . $action, 'db_') == 1) {
echo PMA_generate_common_hidden_inputs($db);
} elseif (strpos(' ' . $action, 'tbl_') == 1
|| $what == 'row_delete') {

View File

@@ -5,7 +5,7 @@
* functions for displaying the sql query form
*
* @usedby server_sql.php
* @usedby db_details.php
* @usedby db_sql.php
* @usedby tbl_sql.php
* @usedby tbl_structure.php
* @usedby querywindow.php
@@ -18,7 +18,7 @@ require_once './libraries/bookmark.lib.php'; // used for file listing
* prints the sql query boxes
*
* @usedby server_sql.php
* @usedby db_details.php
* @usedby db_sql.php
* @usedby tbl_sql.php
* @usedby tbl_structure.php
* @usedby querywindow.php
@@ -90,7 +90,7 @@ function PMA_sqlQueryForm($query = true, $display_tab = false)
// prepare for db related
$db = $GLOBALS['db'];
$goto = empty($GLOBALS['goto']) ?
'db_details.php' : $GLOBALS['goto'];
'db_sql.php' : $GLOBALS['goto'];
} else {
$table = $GLOBALS['table'];
$db = $GLOBALS['db'];

View File

@@ -105,7 +105,7 @@ if ( ! (isset($db_is_information_schema) && $db_is_information_schema) ) {
$tabs['drop']['args']['purge'] = 1;
$drop_command = 'DROP ' . ($tbl_is_view ? 'VIEW' : 'TABLE');
$tabs['drop']['args']['sql_query'] = $drop_command . ' ' . PMA_backquote($table);
$tabs['drop']['args']['goto'] = 'db_details_structure.php';
$tabs['drop']['args']['goto'] = 'db_structure.php';
$tabs['drop']['args']['zero_rows'] = sprintf(($tbl_is_view ? $strViewHasBeenDropped : $strTableHasBeenDropped), htmlspecialchars($table));
$tabs['drop']['attr'] = 'onclick="return confirmLink(this, \'' . $drop_command . ' ' . PMA_jsFormat($table) . '\')"';
unset($drop_command);