Jump to content

Manual:Hooks/RedirectSpecialArticleRedirectParams

From mediawiki.org
RedirectSpecialArticleRedirectParams
Available from version 1.20.0
Lets you alter the set of parameter names such as "oldid" that are preserved when using redirecting special pages such as Special:MyPage and Special:MyTalk.
Define function:
public static function onRedirectSpecialArticleRedirectParams( &$redirectParams ) { ... }
Attach hook: In extension.json:
{
	"Hooks": {
		"RedirectSpecialArticleRedirectParams": "MediaWiki\\Extension\\MyExtension\\Hooks::onRedirectSpecialArticleRedirectParams"
	}
}
Called from: File(s): SpecialPage.php
Interface: RedirectSpecialArticleRedirectParamsHook.php

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


Details

[edit]
  • &$redirectParams: An array of parameters preserved by redirecting special pages.