MediaWiki master
MediaWiki\Widget\SearchInputWidget Class Reference

Search input widget. More...

Inherits MediaWiki\Widget\TitleInputWidget.

Collaboration diagram for MediaWiki\Widget\SearchInputWidget:

Public Member Functions

 __construct (array $config=[])
 
 getConfig (&$config)
 

Protected Member Functions

 getInputElement ( $config)
 
 getJavaScriptClassName ()
 

Protected Attributes

string $dataLocation = 'header'
 
bool $highlightFirst = false
 
bool $performSearchOnClick = true
 
bool $showDescriptions = false
 
bool $validateTitle = false
 
- Protected Attributes inherited from MediaWiki\Widget\TitleInputWidget
bool null $highlightFirst = null
 
int null $namespace = null
 
bool null $relative = null
 
bool null $suggestions = null
 
bool null $validateTitle = null
 

Detailed Description

Search input widget.

Note
2011-2015 MediaWiki Widgets Team and others; see AUTHORS.txt
MIT

Definition at line 13 of file SearchInputWidget.php.

Constructor & Destructor Documentation

◆ __construct()

MediaWiki\Widget\SearchInputWidget::__construct ( array $config = [])
Parameters
array$configConfiguration options
  • bool|null $config['performSearchOnClick'] If true, the script will start a search whenever a user hits a suggestion. If false, the text of the suggestion is inserted into the text field only (default: true)
  • string $config['dataLocation'] Where the search input field will be used (header or content, default: header)

Reimplemented from MediaWiki\Widget\TitleInputWidget.

Definition at line 34 of file SearchInputWidget.php.

Member Function Documentation

◆ getConfig()

MediaWiki\Widget\SearchInputWidget::getConfig ( & $config)

◆ getInputElement()

MediaWiki\Widget\SearchInputWidget::getInputElement ( $config)
protected

Definition at line 66 of file SearchInputWidget.php.

◆ getJavaScriptClassName()

MediaWiki\Widget\SearchInputWidget::getJavaScriptClassName ( )
protected

Reimplemented from MediaWiki\Widget\TitleInputWidget.

Definition at line 70 of file SearchInputWidget.php.

Member Data Documentation

◆ $dataLocation

string MediaWiki\Widget\SearchInputWidget::$dataLocation = 'header'
protected

Definition at line 22 of file SearchInputWidget.php.

Referenced by MediaWiki\Widget\SearchInputWidget\getConfig().

◆ $highlightFirst

bool MediaWiki\Widget\SearchInputWidget::$highlightFirst = false
protected

Definition at line 20 of file SearchInputWidget.php.

◆ $performSearchOnClick

bool MediaWiki\Widget\SearchInputWidget::$performSearchOnClick = true
protected

Definition at line 16 of file SearchInputWidget.php.

Referenced by MediaWiki\Widget\SearchInputWidget\getConfig().

◆ $showDescriptions

bool MediaWiki\Widget\SearchInputWidget::$showDescriptions = false
protected

Definition at line 24 of file SearchInputWidget.php.

◆ $validateTitle

bool MediaWiki\Widget\SearchInputWidget::$validateTitle = false
protected

Definition at line 18 of file SearchInputWidget.php.


The documentation for this class was generated from the following file: