Extension:CheckUser/Hooks/SpecialCheckUserGetLinksFromRow

From mediawiki.org
Jump to navigation Jump to search
SpecialCheckUserGetLinksFromRow
Available from version 1.23.0 (Gerrit change 111249)
Allows controlling the links rendered for a check user row
Define function:
public static function onSpecialCheckUserGetLinksFromRow( SpecialCheckUser $specialCheckUser, stdClass $row, array &$links ) { ... }
Attach hook:
$wgHooks['SpecialCheckUserGetLinksFromRow'][] = 'MyExtensionHooks::onSpecialCheckUserGetLinksFromRow';
Called from:File(s): CheckUser / includes/specials/SpecialCheckUser.php
Function(s): getLinksFromRow

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

A hook that wants to override the default generated links must adjust or replace strings in the &$links variable. Any string added to &$links must be properly escaped. For convenience the strings in &$links have array keys, but they are not rendered.

Parameters[edit]

  • $specialCheckUser: An instance of SpecialCheckUser
  • $row: Database row from the cu_changes table, instance of stdClass
  • &$links: An array of HTML strings