Hi folks I just came across a weird behavior — I don't seem to be able using the PHP PHP: ob_start("ob_gzhandler"); for compressing the output. When throwing in a file like PHP: <?phpob_start("ob_gzhandler");phpinfo();?> in Code: /home/admispconfig/ispconfig/web/test.php it results in Code: HTTP_ACCEPT_ENCODING gzip,deflate But Code: Response Headers: Date: Wed, 23 Apr 2008 02:08:43 GMT Server: Apache X-Powered-By: PHP/5.2.5 Keep-Alive: timeout=15, max=100 Connection: Keep-Alive Transfer-Encoding: chunked Content-Type: text/html 200 OK When I put the same file in a normal user web it results in Code: HTTP_ACCEPT_ENCODING gzip,deflate Code: Response Headers: Date: Wed, 23 Apr 2008 02:08:25 GMT Server: Apache/2.0.55 (Ubuntu) PHP/5.1.2 mod_ssl/2.0.55 OpenSSL/0.9.8a X-Powered-By: PHP/5.1.2 [B]Content-Encoding: gzip[/B] Vary: Accept-Encoding Keep-Alive: timeout=15, max=99 Connection: Keep-Alive Transfer-Encoding: chunked Content-Type: text/html; charset=UTF-8 200 OK So here it does work as supposed. For the admin panel it does not bother me too much, but when using Roundcube webmail it would be a great improvement, of course. They try to use it when supported with this function: PHP: // set output bufferingif ($_action != 'get' && $_action != 'viewsource'){ // use gzip compression if supported if (function_exists('ob_gzhandler') && !ini_get('zlib.output_compression') && ini_get('output_handler') != 'ob_gzhandler') { ob_start('ob_gzhandler'); } else ob_start();} But have no luck here Any ideas/help on that? Thanks
Thanks Till But hmmm, why do I get an Code: ACCEPT-ENCODING gzip,deflate from the PHP: <?php phpinfo(); ?> Cheers
I think you'd have to build mod_gzip for ISPConfig's Apache. http://www.howtoforge.com/linux_apache_mod_gzip_5