Jump to content

Manual:Hooks/SkinSubPageSubtitle

From mediawiki.org
SkinSubPageSubtitle
Available from version 1.12.0
Called before building the list of subpage links above a subpage
Define function:
public static function onSkinSubPageSubtitle( &$subpages, $skin, $out ) { ... }
Attach hook: In extension.json:
{
	"Hooks": {
		"SkinSubPageSubtitle": "MediaWiki\\Extension\\MyExtension\\Hooks::onSkinSubPageSubtitle"
	}
}
Called from: File(s): Skin.php
Interface: SkinSubPageSubtitleHook.php

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

Details

[edit]

Called before building the list of subpage links above a subpage (like this page).

Arguments

[edit]
  • &$subpages: Put the subpage links HTML in this variable
  • $skin: Skin object (since 1.17.0)
  • $out: OutputPage object (since 1.21)

Return value

[edit]

Return false if you want the content of $subpages to be displayed (this will override Skin::subPageSubtitle()'s functionality), return true if you want the default set of links to be generated (unless, of course, another hook overrides).