You are here

function dba_database_overview_form_submit in Database Administration 5

File

./dba.module, line 503
Allows administrators direct access to their Drupal database. Written by Jeremy Andrews <jeremy@kerneltrap.org>, June 2004. PostgreSQL functionality provided by AAM <aam@ugpl.de> Major security audit, porting, and maintenance by Derek…

Code

function dba_database_overview_form_submit($form_id, $form_values) {
  $op = isset($_POST['op']) ? $_POST['op'] : '';

  // We already validated the overview form, so we know we have tables.
  $form_tables = array_keys(array_filter($form_values['tables']));
  $_SESSION['dba_tables'] = dba_get_active_tables(0, $form_tables);
  switch ($op) {
    case t('Check'):
      return 'admin/build/database/check';
    case t('Optimize'):
      return 'admin/build/database/optimize';
    case t('Backup'):
      return 'admin/build/database/backup';
    case t('Empty'):
      return 'admin/build/database/empty';
    case t('Drop'):
      return 'admin/build/database/drop';
  }
}