< Manual:Hooks
ImgAuthModifyHeaders | |
---|---|
Available from version 1.34.0 (Gerrit change 496705) Executed just before a file is streamed to a user, allowing headers to be modified beforehand. | |
Define function: | public static function onImgAuthModifyHeaders( \MediaWiki\Linker\LinkTarget $title, array &$headers ) { ... }
|
Attach hook: | In extension.json:
{
"Hooks": {
"ImgAuthModifyHeaders": "MyExtensionHooks::onImgAuthModifyHeaders"
}
}
|
Called from: | File(s): ../img_auth.php Function(s): wfImageAuthMain |
Interface: | ImgAuthModifyHeadersHook.php |
For more information about attaching hooks, see Manual:Hooks
For examples of extensions using this hook, see Category:ImgAuthModifyHeaders extensions.
Details
$title
:MediaWiki\Linker\LinkTarget
instance&$headers
: Associative array of HTTP headers
This article is issued from Mediawiki. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.