$sval) { switch ($what) { case 'row_delete': $full_query .= htmlspecialchars($sval) . ';
'; break; case 'drop_db': $full_query .= 'DROP DATABASE ' . PMA_backquote(htmlspecialchars($sval)) . ';
'; $reload = 1; break; case 'drop_tbl': $current = $sval; if (!empty($views) && in_array($current, $views)) { $full_query_views .= (empty($full_query_views) ? 'DROP VIEW ' : ', ') . PMA_backquote(htmlspecialchars($current)); } else { $full_query .= (empty($full_query) ? 'DROP TABLE ' : ', ') . PMA_backquote(htmlspecialchars($current)); } break; case 'empty_tbl': $full_query .= 'TRUNCATE '; $full_query .= PMA_backquote(htmlspecialchars($sval)) . ';
'; break; case 'primary_fld': if ($full_query == '') { $full_query .= 'ALTER TABLE ' . PMA_backquote(htmlspecialchars($table)) . '
  DROP PRIMARY KEY,' . '
   ADD PRIMARY KEY(' . '
     ' . PMA_backquote(htmlspecialchars($sval)) . ','; } else { $full_query .= '
     ' . PMA_backquote(htmlspecialchars($sval)) . ','; } if ($i == $selected_cnt-1) { $full_query = preg_replace('@,$@', ');
', $full_query); } break; case 'drop_fld': if ($full_query == '') { $full_query .= 'ALTER TABLE ' . PMA_backquote(htmlspecialchars($table)); } $full_query .= '
  DROP ' . PMA_backquote(htmlspecialchars($sval)) . ','; if ($i == $selected_cnt - 1) { $full_query = preg_replace('@,$@', ';
', $full_query); } break; } // end switch $i++; } if ($what == 'drop_tbl') { if (!empty($full_query)) { $full_query .= ';
' . "\n"; } if (!empty($full_query_views)) { $full_query .= $full_query_views . ';
' . "\n"; } unset($full_query_views); } // Displays the confirmation form $_url_params = array( 'query_type' => $what, 'reload' => (! empty($reload) ? 1 : 0), ); if (strpos(' ' . $action, 'db_') == 1) { $_url_params['db']= $db; } elseif (strpos(' ' . $action, 'tbl_') == 1 || $what == 'row_delete') { $_url_params['db']= $db; $_url_params['table']= $table; } foreach ($selected as $idx => $sval) { $_url_params['selected'][] = $sval; } if ($what == 'drop_tbl' && !empty($views)) { foreach ($views as $current) { $_url_params['views'][] = $current; } } if ($what == 'row_delete') { $_url_params['original_sql_query'] = $original_sql_query; $_url_params['original_url_query'] = $original_url_query; } ?>
:
databases->build(); } } else { $message = PMA_Message::success('strNoModification'); } ?>