Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Text.php

function Text::render

Overrides AreaPluginBase::render

File

core/modules/views/src/Plugin/views/area/Text.php, line 60

Class

Text
Views area text handler.

Namespace

Drupal\views\Plugin\views\area

Code

public function render($empty = FALSE) {
    $format = $this->options['content']['format'] ?? filter_default_format();
    if (!$empty || !empty($this->options['empty'])) {
        return [
            '#type' => 'processed_text',
            '#text' => $this->tokenizeValue($this->options['content']['value']),
            '#format' => $format,
        ];
    }
    return [];
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal