MediaWiki REL1_35
MediaWiki\Hook\ImgAuthModifyHeadersHook Interface Reference

Stable to implement. More...

Inheritance diagram for MediaWiki\Hook\ImgAuthModifyHeadersHook:

Public Member Functions

 onImgAuthModifyHeaders ( $title, &$headers)
 This hook is called just before a file is streamed to a user via img_auth.php, allowing headers to be modified beforehand.
 

Detailed Description

Stable to implement.

Definition at line 11 of file ImgAuthModifyHeadersHook.php.

Member Function Documentation

◆ onImgAuthModifyHeaders()

MediaWiki\Hook\ImgAuthModifyHeadersHook::onImgAuthModifyHeaders (   $title,
$headers 
)

This hook is called just before a file is streamed to a user via img_auth.php, allowing headers to be modified beforehand.

Since
1.35
Parameters
LinkTarget$title
string[]&$headersHTTP headers ( name => value, names are case insensitive ). Two headers get special handling: If-Modified-Since (value must be a valid HTTP date) and Range (must be of the form "bytes=(\\d*-\\d*)") will be honored when streaming the file.
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: