X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fmedia%2FMediaHandler.php;h=fb305db4cf5461f2b4ca82a6d88a519cdd51135e;hb=88a586a12cf9e4674b20ebc060aca2cd9fdb7054;hp=965099fdad272570516f22d88f42015b1144b6b0;hpb=67bfdc7a68940d901e585eadd984a2074bf0216a;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/media/MediaHandler.php b/includes/media/MediaHandler.php index 965099fdad..fb305db4cf 100644 --- a/includes/media/MediaHandler.php +++ b/includes/media/MediaHandler.php @@ -135,9 +135,9 @@ abstract class MediaHandler { */ static function getMetadataVersion () { $version = Array( '2' ); // core metadata version - wfRunHooks('GetMetadataVersion', Array(&$version)); + wfRunHooks( 'GetMetadataVersion', Array( &$version ) ); return implode( ';', $version); - } + } /** * Convert metadata version. @@ -243,6 +243,15 @@ abstract class MediaHandler { return array( $ext, $mime ); } + /** + * Get useful response headers for GET/HEAD requests for a file with the given metadata + * @param $metadata mixed Result of the getMetadata() function of this handler for a file + * @return Array + */ + public function getStreamHeaders( $metadata ) { + return array(); + } + /** * True if the handled types can be transformed * @return bool @@ -356,7 +365,7 @@ abstract class MediaHandler { * @return array for use displaying metadata. */ function formatMetadataHelper( $metadataArray ) { - $result = array( + $result = array( 'visible' => array(), 'collapsed' => array() );