MediaWiki master
MediaWiki\Hook\UploadForm_BeforeProcessingHook Interface Reference

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

Inherited by MediaWiki\HookContainer\HookRunner.

Public Member Functions

 onUploadForm_BeforeProcessing ( $upload)
 This hook is called at the beginning of processUpload().
 

Detailed Description

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

Use the hook name "UploadForm:BeforeProcessing" to register handlers implementing this interface.

Stability: stable
to implement

Definition at line 15 of file UploadForm_BeforeProcessingHook.php.

Member Function Documentation

◆ onUploadForm_BeforeProcessing()

MediaWiki\Hook\UploadForm_BeforeProcessingHook::onUploadForm_BeforeProcessing ( $upload)

This hook is called at the beginning of processUpload().

Lets you poke at member variables like $mUploadDescription before the file is saved. Do not use this hook to break upload processing. This will return the user to a blank form with no error message; use UploadVerifyUpload or UploadVerifyFile instead.

Since
1.35
Parameters
SpecialUpload$upload
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: