You are here

public function DisplayTest::execute in Views (for Drupal 7) 8.3

Overrides Drupal\views\Plugin\views\display\DisplayPluginBase::execute().

Overrides DisplayPluginBase::execute

1 call to DisplayTest::execute()
DisplayTest::preview in tests/views_test_data/lib/Drupal/views_test_data/Plugin/views/display/DisplayTest.php
Overrides Drupal\views\Plugin\views\display\DisplayPluginBase::preview().

File

tests/views_test_data/lib/Drupal/views_test_data/Plugin/views/display/DisplayTest.php, line 114
Definition of Drupal\views_test_data\Plugin\views\display\DisplayTest.

Class

DisplayTest
Defines a Display test plugin.

Namespace

Drupal\views_test_data\Plugin\views\display

Code

public function execute() {
  $this->view
    ->build();

  // Render the test option as the title before the view output.
  $render = '<h1>' . filter_xss_admin($this->options['test_option']) . '</h1>';

  // And now render the view.
  $render .= $this->view
    ->render();
  return $render;
}