com web/php: Disable compression, if set by INI, for images: .router.php

From: Date: Wed, 04 Dec 2013 07:24:04 +0000
Subject: com web/php: Disable compression, if set by INI, for images: .router.php
Groups: php.webmaster 
Request: Send a blank email to php-webmaster+get-22408@lists.php.net to get a copy of this message
Commit: 2e7616fdb4cb0d09f829f6240f4c96f5a09191e3 Author: Hannes Magnusson <bjori@mongodb.com> Tue, 3 Dec 2013 23:24:04 -0800 Parents: 403cfa22154905380917d02166949ac9d9685275 Branches: master Link: http://git.php.net/?p=web/php.git;a=commitdiff;h=2e7616fdb4cb0d09f829f6240f4c96f5a09191e3 Log: Disable compression, if set by INI, for images Changed paths: M .router.php Diff: diff --git a/.router.php b/.router.php index 71e2c6e..b411187 100644 --- a/.router.php +++ b/.router.php @@ -8,6 +8,8 @@ $len = strlen($_SERVER["DOCUMENT_ROOT"]); if (strncmp($_SERVER["DOCUMENT_ROOT"], $afilename, $len) == 0) { if (file_exists($afilename)) { + /* This could be an image or whatever, so don't try to compress it */ + ini_set("zlib.output_compression", 0); return false; } }

« previous php.webmaster (#22408) next »