Manual:Hooks/FileDeleteComplete
From MediaWiki.org
| FileDeleteComplete | |
|---|---|
| Available from version 1.13.0 When a file is deleted |
|
*Define function: |
function fnMyHook( $file, $oldimage, $article, $user, $reason ) { ... }
|
*Attach hook: |
$wgHooks['FileDeleteComplete'][] = 'MyExtensionHooks::someExample'; |
| Called from: | FileDeleteForm.php |
*For more information about attaching hooks, see Manual:Hooks.
*For examples of extensions using this hook, see Category:FileDeleteComplete extensions.
[edit] Details
- $file: reference to the deleted file
- $oldimage: in case of the deletion of an old image, the name of the old file
- $article: in case all revisions of the file are deleted a reference to the article associated with the file.
- $user: user who performed the deletion
- $reason: reason
