It is currently Fri Mar 29, 2024 3:13 am


The forum is READ ONLY. Please direct any future discussions to our Facebook page


 Page 2 of 2 [ 26 posts ]  Go to page Previous  1, 2
Author Message
 Post subject:
PostPosted: Sat Jun 05, 2004 7:58 pm 
Newbie
Newbie

Joined: Sat Nov 29, 2003 1:21 pm
Posts: 37
Ok, Check this
Turned zlib output compression Off in my Php.ini
Not only did the Strange symbols go away and
the white screen flashes disappear But the Game
Still Works at Compression Level 9 :lol:


LV


Offline
 Profile  
 
 Post subject:
PostPosted: Sat Jun 05, 2004 8:29 pm 
Developer
Developer
User avatar

Joined: Wed Feb 19, 2003 6:07 pm
Posts: 2930
BTW, just so you know...

Compression level 0 means No Compression and it bypasses the compression routines. This is why your output worked just fine when you set it to 0 when you have zlib compression enabled in php and the games gzip compression enabled. But any other compression level would cause a junk output to any browser because it is a compression of an already compressed file.



_________________
PJ's Annoyingly Useless Blog
ADOdb Lite
Template Lite
Offline
 Profile  
 
 Post subject:
PostPosted: Sat Jun 05, 2004 8:33 pm 
Developer
Developer
User avatar

Joined: Wed Feb 19, 2003 6:07 pm
Posts: 2930
iamsure wrote:
If you get those, you almost definitely have zlib.compression enabled in php.ini, which is INCOMPATIBLE with gzip compression.

Turn off zlib.compression, and everything will work right.



Actually that's not correct.

If you have zlib compression enabled in PHP you shouldn't turn on the games gzip compression. When zlib is enabled in php then all web output from the server is gzip compressed by default.

Using the games gzip compression is only for use on servers that do not have site wide zlib compression enabled in php. Enabling the games gzip on a server with zlib compression enabled means you will be gzipping already gzipped data thereby creating total garbage output.



_________________
PJ's Annoyingly Useless Blog
ADOdb Lite
Template Lite
Offline
 Profile  
 
 Post subject:
PostPosted: Sat Jun 05, 2004 9:19 pm 
Panama Jack wrote:
BTW, just so you know...

Compression level 0 means No Compression and it bypasses the compression routines. This is why your output worked just fine when you set it to 0 when you have zlib compression enabled in php and the games gzip compression enabled.


Not true.

Go here: http://www.desilva.biz/gzip-test.php

Setup a game with zlib off (obviously), and gzip (in aat) DISABLED, load, and it will show it as disabled.

Then setup the game with gzip ENABLED, at level 0, and it shows it as compressed, shows the gzip content-type, and has a smaller content length.

I thought that as well, until I tested it.


  
 
 Post subject:
PostPosted: Sat Jun 05, 2004 9:21 pm 
Panama Jack wrote:
iamsure wrote:
If you get those, you almost definitely have zlib.compression enabled in php.ini, which is INCOMPATIBLE with gzip compression.

Turn off zlib.compression, and everything will work right.



Actually that's not correct.

If you have zlib compression enabled in PHP you shouldn't turn on the games gzip compression. When zlib is enabled in php then all web output from the server is gzip compressed by default.

My point was how to get AAT's gzip working.

As to which is better, in AAT, I get better compression from gzip compression in the game at level 9, than I do from zlib, since zlib in php.ini defaults to a lower setting.

But yes, if its in the php.ini, then the whole server is compressed, which is better.


  
 
 Post subject:
PostPosted: Sat Jun 05, 2004 9:32 pm 
Newbie
Newbie

Joined: Sat Nov 29, 2003 1:21 pm
Posts: 37
Quote:
Actually that's not correct.

If you have zlib compression enabled in PHP you shouldn't turn on the games gzip compression. When zlib is enabled in php then all web output from the server is gzip compressed by default.

Using the games gzip compression is only for use on servers that do not have site wide zlib compression enabled in php. Enabling the games gzip on a server with zlib compression enabled means you will be gzipping already gzipped data thereby creating total garbage output.


Ok, after some more deeper looking I've noticed some else.

When zlib is turned off in the php.ini I can Enable Gzip in the game
at all compression levels BUT When I run the install.php It shows
something strange. It shows I can enable G-zip compression But
it also Shows Zlib Output compression to be Turned off.

When I turn zlib compression on in the php.ini and turn G-zip off
in the the settings the Install.php shows not only can I enable G-zip
But Now the Zlib compression shows to Be Enabled also.

Is this Right? If this is working as designed this would be Very Confusing
to people. My problem the whole time was I was trying to turn Gzip on
while the zlib compression was enabled in the Php.ini file.

I did this Because I figured if the Zlib compression showed to be disabled
in the Install.php file then the Gzip couldnt possible be working even if it
said I could turn it on. And when I enabled Gzip in the settings thats when
I got the pick a program to open with message. I'm Sure This has probably
confused other people too.

I agree with what your saying and wondered about it myself.
I see no speed differences in the two configurations and since
by running with the zlib compression enabled in the Php.ini
causes System Wide Gzip I will leave it at that. Thats the
configuration I've been running the whole time anyway. It's
Nice to Know My Web Server Compress's ALL Php Output in
Gzip format. :wink:

This Finally clears up something I worked at and wondered
about for a Long Time. Thanks Guys...

LV


Offline
 Profile  
 
 Post subject:
PostPosted: Sat Jun 05, 2004 10:02 pm 
Developer
Developer
User avatar

Joined: Wed Feb 19, 2003 6:07 pm
Posts: 2930
Sigh...

It's really very simple.

zlib Installed   Yes - You can enable AATraders gZip output option.


That means you started PHP with the zlib module installed but not activated. You MUST have the module installed for gzip to work in ALL instances.

zlib Output Compression   Disabled


This means that the compression is turned off and the server will not zgip all output from web site. If it says enabled then all html output from every site on that server will be gzip compressed.

You need the above to be disabled if you want to use the gzip option in the game. If it isn't then the server is already gzipping all output.


Last edited by Panama Jack on Sat Jun 05, 2004 10:37 pm, edited 1 time in total.


_________________
PJ's Annoyingly Useless Blog
ADOdb Lite
Template Lite
Offline
 Profile  
 
 Post subject:
PostPosted: Sat Jun 05, 2004 10:35 pm 
Newbie
Newbie

Joined: Sat Nov 29, 2003 1:21 pm
Posts: 37
Quote:
Not true.

Go here: http://www.desilva.biz/gzip-test.php

Setup a game with zlib off (obviously), and gzip (in aat) DISABLED, load, and it will show it as disabled.



Its getting Deep :wink:

Iamsure, Love the G-zip test link. thanks.

When I test it with the Game Gzip Disabled and Zlib Enabled I get a 63%
compression rating in Alien assault and also my Green dragon game.
I get a 83% compression on my photo gallery program.

I havent tried it yet with the Game Gzip enabled and zlib disabled But
even if the alien assault compression is better at 9, Losing Server wide
Gzip seems to be too high a price to pay.

When zlib is enabled in the php file I notice phpinfo shows zlib
compression level to be -1. Ive looked in the php.ini file but dont
see a Switch to set the compression level. Can this be adjusted
and if so How and to what.

Also I noticed in the test readout Under Cache Control & Pragma is shows
No Cache. Hmmm, what does this indicate. I use mmcache in my php.ini
file. Is this something to be concerned about.


Offline
 Profile  
 
 Post subject:
PostPosted: Sat Jun 05, 2004 11:08 pm 
LordVngr wrote:
Also I noticed in the test readout Under Cache Control & Pragma is shows
No Cache. Hmmm, what does this indicate. I use mmcache in my php.ini
file. Is this something to be concerned about.

No.

Due to the extremely interactive/dynamic nature of the game, almost no file in the game is "unchanged" from view to view.

Normally, on a site like oh, cnn, the main page doesnt change for 20-30 minutes at a time. So, if you re-visit it, the server (and ideally, the browser) will respond with a cached version. Thats what that line refers to. Its not related to using mmcache at all.

As to the zlib compression level, not positive.. I beleive there is a way to do so, but I'm not sure (pun intended!) how to change it.


  
 
 Post subject:
PostPosted: Sat Jun 05, 2004 11:45 pm 
Newbie
Newbie

Joined: Sat Nov 29, 2003 1:21 pm
Posts: 37
Panama Jack wrote:
Sigh...

It's really very simple.




PJ

Well Now that I understand yes it Is Simple.
But trust me for the Newbies out there its
confusing. :wink:

LV


Offline
 Profile  
 
 Post subject:
PostPosted: Sun Jun 06, 2004 12:00 am 
Newbie
Newbie

Joined: Sat Nov 29, 2003 1:21 pm
Posts: 37
All rightee then

Just ran the gzip test with zlib disabled and Gzip enabled in the game.
At All compression levels including 0 When I ran the test on alien assault
it shows its compressed But under savings it shows insufficent data instead
of a %.

When I test green dragon or my photo gallery it shows Neither are
compressed. This is As Expected.

For me personnaly the answer is now crystal clear.
The Game Gzip Disabled and Zlib enabled in the Php.ini.
This has been a Most helpfull and Informative thread.
Thanks Guys...

LV


Offline
 Profile  
 
Display posts from previous:  Sort by  
 Page 2 of 2 [ 26 posts ]  Go to page Previous  1, 2


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  

cron