1 views_ui_base_views_wizard.php protected ViewsUiBaseViewsWizard::build_display_options($form, $form_state)

Build an array of display options for the view.

Return value

An array whose keys are the names of each display and whose values are: arrays of options for that display.


core/modules/views_ui/wizards/views_ui_base_views_wizard.php, line 516
Provides the interface and base class for Views Wizard plugins.


A very generic Views Wizard class - can be constructed for any base table.


protected function build_display_options($form, $form_state) {
  // Display: Default
  $display_options['default'] = $this->default_display_options($form, $form_state);
  $display_options['default'] += array(
    'filters' => array(),
    'sorts' => array(),
  $display_options['default']['filters'] += $this->default_display_filters($form, $form_state);
  $display_options['default']['sorts'] += $this->default_display_sorts($form, $form_state);

  // Display: Page
  if (!empty($form_state['values']['page']['create'])) {
    $display_options['page'] = $this->page_display_options($form, $form_state);

    // Display: Feed (attached to the page)
    if (!empty($form_state['values']['page']['feed'])) {
      $display_options['feed'] = $this->page_feed_display_options($form, $form_state);

  // Display: Block
  if (!empty($form_state['values']['block']['create'])) {
    $display_options['block'] = $this->block_display_options($form, $form_state);

  return $display_options;