summaryrefslogtreecommitdiff
path: root/includes/StreamFile.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/StreamFile.php')
-rw-r--r--includes/StreamFile.php14
1 files changed, 9 insertions, 5 deletions
diff --git a/includes/StreamFile.php b/includes/StreamFile.php
index 6db66ba8..5f460ee3 100644
--- a/includes/StreamFile.php
+++ b/includes/StreamFile.php
@@ -1,5 +1,9 @@
<?php
-/** */
+/**
+ * Functions related to the output of file content
+ *
+ * @file
+ */
/** */
function wfStreamFile( $fname, $headers = array() ) {
@@ -37,8 +41,8 @@ function wfStreamFile( $fname, $headers = array() ) {
return;
}
- global $wgContLanguageCode;
- header( "Content-Disposition: inline;filename*=utf-8'$wgContLanguageCode'" . urlencode( basename( $fname ) ) );
+ global $wgLanguageCode;
+ header( "Content-Disposition: inline;filename*=utf-8'$wgLanguageCode'" . urlencode( basename( $fname ) ) );
foreach ( $headers as $header ) {
header( $header );
@@ -91,8 +95,8 @@ function wfGetType( $filename, $safe = true ) {
*/
if ( $safe ) {
global $wgFileBlacklist, $wgCheckFileExtensions, $wgStrictFileExtensions,
- $wgFileExtensions, $wgVerifyMimeType, $wgMimeTypeBlacklist, $wgRequest;
- list( $partName, $extList ) = UploadBase::splitExtensions( $filename );
+ $wgFileExtensions, $wgVerifyMimeType, $wgMimeTypeBlacklist;
+ list( , $extList ) = UploadBase::splitExtensions( $filename );
if ( UploadBase::checkFileExtensionList( $extList, $wgFileBlacklist ) ) {
return 'unknown/unknown';
}