Improve documentation for content type choice
authorTim Starling <tstarling@users.mediawiki.org>
Tue, 24 Jan 2012 22:22:19 +0000 (22:22 +0000)
committerTim Starling <tstarling@users.mediawiki.org>
Tue, 24 Jan 2012 22:22:19 +0000 (22:22 +0000)
includes/StreamFile.php

index dc70712..55c5e48 100644 (file)
@@ -78,6 +78,10 @@ class StreamFile {
                if ( $type && $type != 'unknown/unknown' ) {
                        header( "Content-type: $type" );
                } else {
+                       // Send a content type which is not known to Internet Explorer, to
+                       // avoid triggering IE's content type detection. Sending a standard
+                       // unknown content type here essentially gives IE license to apply
+                       // whatever content type it likes.
                        header( 'Content-type: application/x-wiki' );
                }