Manual:Hooks/LocalFile::getHistory

From Linux Web Expert

LocalFile::getHistory
<translate> Available from <tvar name=1><translate> version <tvar </tvar></translate>
Called before file history query performed.
<translate> Define function:</translate>
public static function onLocalFile_getHistory( $file, $tables, $fields, $conds, $opts, $join_conds ) { ... }
<translate> Attach hook:</translate> <translate> In <tvar name=1>extension.json</tvar>:</translate>
{
	"Hooks": {
		"LocalFile::getHistory": "MediaWiki\\Extension\\MyExtension\\Hooks::onLocalFilegetHistory"
	}
}
<translate> Called from:</translate> <translate> File(s):</translate> LocalFile.php
<translate> Interface:</translate> LocalFile__getHistoryHook.php

<translate> For more information about attaching hooks, see <tvar name=1>Manual:Hooks </tvar>.</translate>
<translate> For examples of extensions using this hook, see <tvar name=cat>Category:LocalFile::getHistory extensions</tvar>.</translate>

Details

  • $file: the file
  • $tables: tables
  • $fields: select fields
  • $conds: conditions
  • $opts: query options
  • $join_conds: JOIN conditions