Ending the buffering completely will kill all subsequent output when
PHP is globally configured to run through a gzip compression handler.
Also, suppress the warning in LocalSettings.php when PHP tells us we
can't run the gzip filter twice.
}
} elseif ( empty( \$wgConfiguring ) ) {
## Compress output if the browser supports it
- {$zlib}if( !ini_get( 'zlib.output_compression' ) ) ob_start( 'ob_gzhandler' );
+ {$zlib}if( !ini_get( 'zlib.output_compression' ) ) @ob_start( 'ob_gzhandler' );
}
\$wgSitename = \"{$slconf['Sitename']}\";
<?php
function install_version_checks() {
- # Turn off output buffering if it's on
- @ob_end_flush();
+ # We dare not turn output buffer _off_ since this will break completely
+ # if PHP is globally configured to run through a gzip filter.
+ @ob_implicit_flush( true );
if( !function_exists( "version_compare" ) ) {
# version_compare was introduced in 4.1.0