Manual:Hooks/SpecialSearchNoResults

From mediawiki.org
Jump to navigation Jump to search
SpecialSearchNoResults
Available from version 1.13.0
Removed in version 1.24.0
called before search result display when there are no matches
Define function:
public static function onSpecialSearchNoResults( $term ) { ... }
Attach hook: In extension.json:
{
	"Hooks": {
		"SpecialSearchNoResults": "MyExtensionHooks::onSpecialSearchNoResults"
	}
}
Called from: File(s): specials/SpecialSearch.php
Interface: SpecialSearchNoResultsHook.php

For more information about attaching hooks, see Manual:Hooks .
For examples of extensions using this hook, see Category:SpecialSearchNoResults extensions.

Details[edit]

  • $term: string of search term