Jump to content

Manual:Hooks/ChangesListInsertArticleLink

From mediawiki.org
ChangesListInsertArticleLink
Available fromversion 1.12.0
Override or augment link to article in RC list.
Define function:
publicstaticfunctiononChangesListInsertArticleLink(ChangesList$changesList,string&$articlelink,string&$s,RecentChange&$rc,bool$unpatrolled,bool$watched){...}
Attach hook: Inextension.json:
{
"Hooks":{
"ChangesListInsertArticleLink":"MediaWiki\\Extension\\MyExtension\\Hooks::onChangesListInsertArticleLink"
}
}
Called from: File(s):changes/ChangesList.php
Function(s):getArticleLink
Interface: ChangesListInsertArticleLinkHook.php

For more information about attaching hooks, seeManual:Hooks.
For examples of extensions using this hook, seeCategory:ChangesListInsertArticleLink extensions.

Details

[edit]
  • $changesList: ChangesList instance.
  • &$articlelink: HTML of link to article (already filled-in).
  • &$s: HTML of row that is being constructed.
  • &$rc: RecentChange instance.
  • $unpatrolled: Whether or not we are showing unpatrolled changes.
  • $watched: Whether or not the change is watched by the user.