Manual:Hooks/ActionModifyFormFields

From MediaWiki.org
Jump to: navigation, search
ActionBeforeFormDisplay
Available from version 1.18.0 (r86001)
Before creating an HTMLForm object for a page action; allows to change the fields on the form that will be generated.

Define function:
public static function onActionBeforeFormDisplay( $name, &$fields, $article ) { ... }

Attach hook:
$wgHooks['ActionBeforeFormDisplay'][] = 'MyExtensionHooks::onActionBeforeFormDisplay';
Called from: Action.php

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


[edit] Details

  • $name: name of the action
  • &$fields: HTMLForm descriptor array
  • $article: Article object
Personal tools
Namespaces

Variants
Actions
Navigation
Support
Download
Development
Communication
Print/export
Toolbox