Manual:Hooks/EditPageNoSuchSection

From Linux Web Expert

EditPageNoSuchSection
<translate> Available from <tvar name=1><translate> version <tvar </tvar></translate>
When a section edit request is given for an non-existent section.
<translate> Define function:</translate>
public static function onEditPageNoSuchSection( $editpage, &$res ) { ... }
<translate> Attach hook:</translate> <translate> In <tvar name=1>extension.json</tvar>:</translate>
{
	"Hooks": {
		"EditPageNoSuchSection": "MediaWiki\\Extension\\MyExtension\\Hooks::onEditPageNoSuchSection"
	}
}
<translate> Called from:</translate> <translate> File(s):</translate> EditPage.php
<translate> Interface:</translate> EditPageNoSuchSectionHook.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:EditPageNoSuchSection extensions</tvar>.</translate>


Details

  • $editpage: The current EditPage object
  • &$res: the HTML of the error text