Manual:Hooks/EditPageBeforeEditChecks
From Linux Web Expert
File:OOjs UI icon alert-destructive.svg | <translate> This feature was removed from MediaWiki core in version <tvar name=ver>1.32.0</tvar> (after being deprecated in <tvar name=4>1.29.0</tvar>).</translate> <translate> Please see <tvar name=page>EditPageGetCheckboxesDefinition</tvar> for an alternative way to use this feature.</translate> |
EditPageBeforeEditChecks | |
---|---|
<translate> Available from <tvar name=1><translate> version <tvar </tvar></translate> <translate> Removed in <tvar name=1><translate> version <tvar (Gerrit change 374870)</tvar></translate> Allows modifying the edit checks below the textarea in the edit form | |
<translate> Define function:</translate> | public static function onEditPageBeforeEditChecks( EditPage &$editpage, array &$checks, &$tabindex ) { ... }
|
<translate> Attach hook:</translate> | <translate> In <tvar name=1>extension.json</tvar>:</translate>
{
"Hooks": {
"EditPageBeforeEditChecks": "MediaWiki\\Extension\\MyExtension\\Hooks::onEditPageBeforeEditChecks"
}
}
|
<translate> Called from:</translate> | <translate> File(s):</translate> EditPage.php |
<translate> Interface:</translate> | EditPageBeforeEditChecksHook.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:EditPageBeforeEditChecks extensions</tvar>.</translate>
Details
- &$editpage: The current EditPage object
- &$checks: Array of edit checks like "watch this page"/"minor edit"
- &$tabindex: HTML
tabindex
of the last edit check/button