< Manual:Hooks
SearchableNamespaces | |
---|---|
Available from version 1.16.0 An option to modify which namespaces are searchable. | |
Define function: | public static function onSearchableNamespaces( &$searchableNamespaces ) { ... }
|
Attach hook: | In extension.json:
{
"Hooks": {
"SearchableNamespaces": "MyExtensionHooks::onSearchableNamespaces"
}
}
|
Called from: | File(s): search/SearchEngine.php |
Interface: | SearchableNamespacesHook.php |
For more information about attaching hooks, see Manual:Hooks
For examples of extensions using this hook, see Category:SearchableNamespaces extensions.
Details
- &$searchableNamespaces: Array of namespaces ($nsId => $name) which will be used.
This article is issued from Mediawiki. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.