Only enable gzip compression if it is not enabled in php.ini. Fixes #4426
git-svn-id: http://svn.automattic.com/wordpress/trunk@5810 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
c510f1060d
commit
75a3af7d17
|
@ -394,7 +394,13 @@ function maybe_serialize($data) {
|
|||
}
|
||||
|
||||
function gzip_compression() {
|
||||
if ( !get_option('gzipcompression') ) return false;
|
||||
if ( !get_option( 'gzipcompression' ) ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if ( ( ini_get( 'zlib.output_compression' ) == 'On' || ini_get( 'zlib.output_compression_level' ) > 0 ) || ini_get( 'output_handler' ) == 'ob_gzhandler' ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if ( extension_loaded( 'zlib' ) ) {
|
||||
ob_start( 'ob_gzhandler' );
|
||||
|
|
Loading…
Reference in New Issue