[Typo3-dev] Bug in class.gzip_encode

4Dfx peter.russ at 4dfx.de
Sat Sep 6 03:37:52 CEST 2003


Peter Russ :: 4Dfx schrieb:

[...]
> 
> Dived into the code and found the problem:
> if the level var is set in $TYPO3_CONF_VARS the type is String (!)
> So to get the compression working you have to fix index.php (line 500) 
> in root.
> 
> i.e.
> // *************
> // Compressions
> // *************
> if ($TYPO3_CONF_VARS["FE"]["compressionLevel"])    {
>     new gzip_encode($TYPO3_CONF_VARS["FE"]["compressionLevel"], false, 
> $GLOBALS["TYPO3_CONF_VARS"]["FE"]["compressionDebugInfo"]);
> }
> 
> and debug:
> // *************
> // Compressions
> // *************
> if ($TYPO3_CONF_VARS["FE"]["compressionLevel"])    {
> /* add this line to convert to Boolean if true
> debug Peter Russ 06.09.2003 beginn */ 
> $complevel=($TYPO3_CONF_VARS["FE"]["compressionLevel"]=='true')?true:$TYPO3_CONF_VARS["FE"]["compressionLevel"]; 
> 
> /* debug end*/
>     new gzip_encode($complevel, false, 
> $GLOBALS["TYPO3_CONF_VARS"]["FE"]["compressionDebugInfo"]);
> }
> 
[...]

As [BE] has also the option to work with compression in several methods 
it might be a better a idea to fix the bug within the 
class.gzip_encode.php. Pls find attached.

Regs. Peter.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: class.gzip_encode.php
Type: application/download
Size: 11667 bytes
Desc: not available
URL: <http://lists.typo3.org/pipermail/typo3-dev/attachments/20030906/e2445e72/attachment.bin>


More information about the TYPO3-dev mailing list