[TYPO3-core] FYI72: #9947: gzip compression does not work in BE at all

Benjamin Mack benni at typo3.org
Sun Dec 21 00:45:44 CET 2008


Hey Dmitry,

does this mean we should deprecate our gzip_compress class?

All the best,
benni.


On 15.12.2008 10:25 Uhr, Dmitry Dulepov wrote:
> Hi!
>
> This is SVN patch request.
>
> Type: bug
>
> Branches: trunk, 4.2, 4.1
>
> BT reference: http://bugs.typo3.org/view.php?id=9947
>
> Problem: typo3/init.php includes class.gzip_compress.php but this is not enough. According to instructions in class.gzip_encode.php there must be another call, which is neither made, nor possible with BE architecture (it is not a problem in FE). Therefore compression never works. class.gzip_encode.php requires either a call to its constructor after output is completed (not possible with Backend modules) or "autoappend" PHP file, which is not possible either.
>
> Solution: the solution is to use PHP built-in output compression handler, which is faster anyway.
>
> Notes: this patch sets compression level according to the documentation on the PHP site. Notice that we cannot use ini_set('zlib.output_compression'), it simply does not work from withing a file (but works from .htaccess). So I decided on ob_gzhandler(), which is old good proven working function. Additionally this bugfix will automatically fix http://bugs.typo3.org/view.php?id=3071 (positive side effect).
>



More information about the TYPO3-team-core mailing list