Manual:Hooks/SearchGetNearMatch

From MediaWiki.org
Jump to: navigation, search
SearchGetNearMatch
Available from version 1.12.0
An extra chance for exact-title-matches in "go" searches

*Define function:
function fnMyHook( $term, &$title ) { ... }

*Attach hook:
$wgHooks['SearchGetNearMatch'][] = 'MyExtensionHooks::someExample';
Called from: SearchEngine.php

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


[edit] Details

  • $term : Search term string
  • &$title : Outparam; set to $title object and return false for a match
Personal tools
Namespaces
Variants
Actions
Site
Support
Download
Development
Communication
Print/export
Toolbox