And while I'm at it: removed unused global declarations of $wgFeedClasses
[lhc/web/wiklou.git] / includes / AjaxResponse.php
index 63468a1..646019d 100644 (file)
@@ -37,15 +37,15 @@ class AjaxResponse {
        /** Content of our HTTP response */
        private $mText;
 
-       function __construct( $text = NULL ) {
-               $this->mCacheDuration = NULL;
-               $this->mVary = NULL;
+       function __construct( $text = null ) {
+               $this->mCacheDuration = null;
+               $this->mVary = null;
 
                $this->mDisabled = false;
                $this->mText = '';
                $this->mResponseCode = '200 OK';
                $this->mLastModified = false;
-               $this->mContentType= 'text/html; charset=utf-8';
+               $this->mContentType= 'application/x-wiki';
 
                if ( $text ) {
                        $this->addText( $text );
@@ -178,6 +178,7 @@ class AjaxResponse {
                        wfDebug( "$fname: -- client send If-Modified-Since: " . $modsince . "\n", false );
                        wfDebug( "$fname: --  we might send Last-Modified : $lastmod\n", false );
                        if( ($ismodsince >= $timestamp ) && $wgUser->validateCache( $ismodsince ) && $ismodsince >= $wgCacheEpoch ) {
+                               ini_set('zlib.output_compression', 0);
                                $this->setResponseCode( "304 Not Modified" );
                                $this->disable();
                                $this->mLastModified = $lastmod;