You are here

function views_ui_admin_edit_page in Views (for Drupal 7) 5

1 string reference to 'views_ui_admin_edit_page'
views_ui_add_menu_items in ./views_ui.module

File

./views_ui.module, line 508

Code

function views_ui_admin_edit_page($vid = '') {
  views_load_cache();
  $op = $_POST['op'];
  if ($op == t('Cancel')) {
    drupal_goto('admin/build/views');
  }
  if ($op == t('Delete')) {
    drupal_goto("admin/build/views/delete/{$vid}");
  }
  if (!($view = _views_load_view($vid))) {
    drupal_goto('admin/build/views');
  }
  drupal_set_title(t('Edit view %n', array(
    '%n' => $view->name,
  )));
  return drupal_get_form('views_edit_view', $view, $op);
}