MediaWiki REL1_35
MediaWiki\Search\Hook\PrefixSearchExtractNamespaceHook Interface Reference

Stable to implement. More...

Inheritance diagram for MediaWiki\Search\Hook\PrefixSearchExtractNamespaceHook:

Public Member Functions

 onPrefixSearchExtractNamespace (&$namespaces, &$search)
 This hook is called if core was not able to extract a namespace from the search string so that extensions can attempt it.
 

Detailed Description

Stable to implement.

Definition at line 9 of file PrefixSearchExtractNamespaceHook.php.

Member Function Documentation

◆ onPrefixSearchExtractNamespace()

MediaWiki\Search\Hook\PrefixSearchExtractNamespaceHook::onPrefixSearchExtractNamespace ( $namespaces,
$search 
)

This hook is called if core was not able to extract a namespace from the search string so that extensions can attempt it.

Since
1.35
Parameters
int[]&$namespacesArray of int namespace keys to search in (change this if you can extract namespaces)
string&$searchSearch term (replace this with term without the namespace if you can extract one)
Returns
bool|void True or no return value to continue or false to abort

Implemented in MediaWiki\HookContainer\HookRunner.


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