Project

General

Profile

Actions

Bug #84562

closed

FE output compressed twice if zlib.output_compression and [FE][compressionLevel] is enabled and backend session exists

Added by Hendrik Becker over 6 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Frontend
Target version:
-
Start date:
2018-03-29
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
7
PHP Version:
5.6
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

This was tested on TYPO3 7.6 as well as 6.2 and produces the same results.

If I activate [FE][compressionLevel] in TYPO3 install tool (e.g. set it to 5)
and activate zlib.output_compression in php.ini (e.g. set it to 16384)
and log-in into the TYPO3 backend as admin, then previewing the frontend shows binary (compressed) data.

This is actually reasonable, because first TYPO3 compresses the output and in addition PHP does it again.

But the thing is, this does not happen, if I have no backend session.
If I browse the frontend without backend session, everything works fine.
A congruent behaviour would be nice here.

If I disable the TYPO3 [FE][compressionLevel] and leave the PHP zlib.output_compression enabled, I have the problem, that TYPO3 does not generate compressed CSS and JS files anymore.
It would be awesome, if I had the option to enable / disable TYPO3 FE output compression selectively or if TYPO3 skips the FE output compression if zlib.output_compression is enabled.
That way I could use zlib.output_compression (for TYPO3 and other PHP applications on the same vhost) in combination with TYPO3 generated compressed CSS and JS files.

I prefer zlib.output_compression because of the PHP documentation: http://php.net/manual/en/function.ob-gzhandler.php
"... note that using zlib.output_compression is preferred over ob_gzhandler()"

My current workaround is:
I disabled the zlib.output_compression in php.ini to fix the symptoms.
In addition I activated mod_deflate.so in apache and added output filtering to compress other applications' outputs.

Actions

Also available in: Atom PDF