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

Breadcrumb

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

function Search::getInfo

Overrides ElementInterface::getInfo

File

core/lib/Drupal/Core/Render/Element/Search.php, line 27

Class

Search
Provides an HTML5 input element with type of "search".

Namespace

Drupal\Core\Render\Element

Code

public function getInfo() {
    $class = static::class;
    return [
        '#input' => TRUE,
        '#size' => 60,
        '#maxlength' => 128,
        '#autocomplete_route_name' => FALSE,
        '#process' => [
            [
                $class,
                'processAutocomplete',
            ],
            [
                $class,
                'processAjaxForm',
            ],
        ],
        '#pre_render' => [
            [
                $class,
                'preRenderSearch',
            ],
        ],
        '#theme' => 'input__search',
        '#theme_wrappers' => [
            'form_element',
        ],
    ];
}

API Navigation

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