Merge "New hook, 'SearchResultInitFromTitle'"
authorAaron Schulz <aschulz@wikimedia.org>
Fri, 7 Sep 2012 20:49:32 +0000 (20:49 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Fri, 7 Sep 2012 20:49:32 +0000 (20:49 +0000)
1  2 
docs/hooks.txt

diff --combined docs/hooks.txt
@@@ -290,12 -290,6 +290,12 @@@ $revCount: Number of revisions in the X
  $sRevCount: Number of sucessfully imported revisions
  $pageInfo: associative array of page information
  
 +'AfterFinalPageOutput': Nearly at the end of OutputPage::output() but
 +before OutputPage::sendCacheControl() and final ob_end_flush() which
 +will send the buffered output to the client. This allows for last-minute
 +modification of the output within the buffer by using ob_get_clean().
 +$output: The OutputPage object where output() was called
 +
  'AjaxAddScript': Called in output page just before the initialisation
  of the javascript ajax engine. The hook is only called when ajax
  is enabled ( $wgUseAjax = true; ).
@@@ -320,13 -314,6 +320,13 @@@ $body: Body of the messag
  Use this to extend core API modules.
  &$module: Module object
  
 +'APICheckCanExecute': Called during ApiMain::checkCanExecute. Use to
 +further authenticate and authorize API clients before executing the
 +module. Return false and set a message to cancel the request.
 +$module: Module object
 +$user: Current user
 +&$message: API usage message to die with
 +
  'APIEditBeforeSave': before saving a page with api.php?action=edit,
  after processing request parameters. Return false to let the request
  fail, returning an error message or an <edit result="Failure"> tag
@@@ -1716,6 -1703,11 +1716,11 @@@ in the $searchEngine->namespaces array
  $query : Original query.
  &$parsed : Resultant query with the prefixes stripped.
  
+ 'SearchResultInitFromTitle': Set the revision used when displaying a page in
+ search results.
+ $title : Current Title object being displayed in search results.
+ &$id: Revision ID (default is false, for latest)
  'SearchableNamespaces': An option to modify which namespaces are searchable.
  &$arr : Array of namespaces ($nsId => $name) which will be used.