MediaWiki master
MediaWiki\Revision\Hook\ContentHandlerDefaultModelForHook Interface Reference

This is a hook handler interface, see docs/Hooks.md. More...

Inherited by MediaWiki\HookContainer\HookRunner.

Public Member Functions

 onContentHandlerDefaultModelFor ( $title, &$model)
 This hook is called when the default content model is determined for a given title.
 

Detailed Description

This is a hook handler interface, see docs/Hooks.md.

Use the hook name "ContentHandlerDefaultModelFor" to register handlers implementing this interface.

Stability: stable
to implement

Definition at line 14 of file ContentHandlerDefaultModelForHook.php.

Member Function Documentation

◆ onContentHandlerDefaultModelFor()

MediaWiki\Revision\Hook\ContentHandlerDefaultModelForHook::onContentHandlerDefaultModelFor ( $title,
& $model )

This hook is called when the default content model is determined for a given title.

Use this hook to assign a different model for that title.

Since
1.35
Parameters
Title$titleTitle in question
string&$modelModel name. Use with CONTENT_MODEL_XXX constants.
Returns
bool|void True or no return value to continue or false to abort

Implemented in MediaWiki\HookContainer\HookRunner.


The documentation for this interface was generated from the following file: