getHeader(); $scripts = $header->getScripts(); $scripts->addFile('tbl_operations.js'); /** * Runs common work */ require './libraries/tbl_common.inc.php'; $url_query .= '&goto=view_operations.php&back=view_operations.php'; $url_params['goto'] = $url_params['back'] = 'view_operations.php'; $operations = new Operations(); /** * Updates if required */ $_message = new Message; $_type = 'success'; if (isset($_REQUEST['submitoptions'])) { if (isset($_REQUEST['new_name'])) { if ($pma_table->rename($_REQUEST['new_name'])) { $_message->addText($pma_table->getLastMessage()); $result = true; $GLOBALS['table'] = $pma_table->getName(); /* Force reread after rename */ $pma_table->getStatusInfo(null, true); $reload = true; } else { $_message->addText($pma_table->getLastError()); $result = false; } } $warning_messages = $operations->getWarningMessagesArray(); } if (isset($result)) { // set to success by default, because result set could be empty // (for example, a table rename) if (empty($_message->getString())) { if ($result) { $_message->addText( __('Your SQL query has been executed successfully.') ); } else { $_message->addText(__('Error')); } // $result should exist, regardless of $_message $_type = $result ? 'success' : 'error'; } if (! empty($warning_messages)) { $_message->addMessagesString($warning_messages); $_message->isError(true); unset($warning_messages); } echo Util::getMessage( $_message, $sql_query, $_type ); } unset($_message, $_type); $url_params['goto'] = 'view_operations.php'; $url_params['back'] = 'view_operations.php'; /** * Displays the page */ ?>
'DROP VIEW ' . Util::backquote( $GLOBALS['table'] ), 'goto' => 'tbl_structure.php', 'reload' => '1', 'purge' => '1', 'message_to_show' => sprintf( __('View %s has been dropped.'), htmlspecialchars($GLOBALS['table']) ), 'table' => $GLOBALS['table'] ) ); echo '
'; echo '
'; echo '' , __('Delete data or table') , ''; echo ''; echo '
'; echo '
';