gzip

GZipping website (js, css, php)

Hey, I have been reading different articles on GZipping and am wondering what is the best way to gzip my files including: PHP JS CSS I saw this article: http://blog.mycila.com/2009/08/godaddy-gzip-compression.html Kind of blurry on the whole deal. Any suggestions? Thanks, Ryan ...

Snippet of page source occasionally appears in the middle of page content

Every so often recently, a subset of our users report seeing small snippets of page source, such as part of a declaration cut off abruptly, displayed in the middle of the page where you would expect the rendered element to appear instead. We know these users use IE6 instead of IE7, and have connections that can sometimes be very slow, ...

Does using gzip encoding make sense for communications within same server?

I have an xml feed supplied by one system which is used by another system and both of them (at the moment at least) are located on the same physical server. In this case would using gzip to encode (large) xml responses slow things down or speed it up, or maybe wont make any difference. ...

WCF REST Compression

I have a REST service that returns a large chunk of XML, about 150k worth. e.g. http://xmlservice.com/services/RestService.svc/GetLargeXML Therefore I want to compress the response from the server, as GZIP should reduce this to something much smaller. Having searched everywhere I cannot for the life of me find an example of how to ...

Why Apache doesn't gzip css or js files which have parameters ?

Hi all, Some CSS & JS files are not compressed by apache with mod_deflate enabled. This files looks like this "[domain.name]/aggregator.css?..." or "[domain.name]/misc/jquery.js?..." in YSlow. The other CSS & JS without the "?" gets compressed. Kindly explain me how do I make apache compress this files also. Thanks ...

iPhone: Reading a gzipped stream

Are they any classes or libraries to read a gzipped stream from a server? For example, Java has the GZIPInputStream and GZIPOutputStream classes to read from a gzipped stream. Does iPhone SDK have such libraries or are there any external libraries that we can use? ...

Compressing with Java Decompressing with PHP

I have a situation where a servlet is providing compressed data to a PHP script. I compress the data on the Java side no problem, but PHP seems unable to decompress. Here is the relevent code snippets Java Side: OutputStream o=response.getOutputStream(); GZIPOutputStream gz=new GZIPOutputStream(o); gz.write(GridCoder.encode(rs,id...

How does the GZip algorithm work?

How does the GZip file compression algorithm work? If anyone has any documentation on this, I'd like to read it. ...

Will all files be compressed by using ob_start("ob_gzhandler"); at line 1 with PHP?

<?php ob_start("ob_gzhandler"); ?> <script type="text/javascript" src="Util.js"></script> <script type="text/javascript" src="connection.js"></script> .... <?php ob_end_flush(); ?> Will the files included by or also be compressed? ...

String table encoding vs. gzip compression

In my application, I need to store and transmit data that contains many repeating string values (think entity names in an XML document). I have two proposed solutions: A) create a string table to be stored along the document, and then use index references (using multi-byte encoding) in the document body, or B) simply compress the do...

GZIPInputStream implementation for J2ME

Are there any GZIPInputStream implementation for J2ME available. I would prefer an Apache Style License ...

Creating and serving zipped files with php

Hi everyone. I'm trying to use the following code to create a zip file from a directory and serve it to the user via an http download: // write the file file_put_contents($path . "/index.html", $output); // zip up the contents chdir($path); exec("zip -r {$course->name} ./"); $filename = "{$course->name}.zip"; header('Content-Type: ...

Prevent server from encoding in gzip when downloading with WebClient

I have a download manager of sorts that uses WebClient.DownloadFileAsync. Webclient doesn't seem to handle gzip encoding and some servers are insisting on using it. Since almost all of the files this will be downloading are already compressed, it would be nice just to be able to force it to stop. I've tried setting the Accept-Encoding t...

tar (on Windows) a list of files in c#

I then to tar and then gzip a list of files in C#. I need some help with how to set the arguments to tar. Say I have tar.exe in a folder c:\tar\tar.exe and a method like the following: private void RunTar(string outputFileName, List<string> fileNamePaths) { using (Process p = new Process()) { p.Star...

DLLHook - GZip decompression of a string

I am injecting a dll into firefox (browser) and hooking WSARecv. The problem is, that the data-buffer is Gzip-compressed. I already tried hooking the send() function and removing the "Accept-Encoding: gzip,deflate", but many webservers won't understand this. So I tried to stick with decompressing the buffer, changing some stuff and comp...

Known issues with gzip and IE6

I read that some versions of IE6 have known issues with gzip compression, but I have found little explanation as to what these issues are. What are the known issues with gzip compression and IE6? ...

Dotnetnuke and gzip

I am currently running Dotnetnuke version 4.9.4 and would like to enable gzip compression. My concern is that IE6 prior to SP2 has known issues with gzipped content. Does the Dotnetnuke framework handle the gzip issues with IE6 or will I need to apply a fix outside of the framework? ...

Python gzip folder structure when zipping single file.

I'm using Python's gzip module to gzip content for a single file, using code similar to the example in the docs: import gzip content = "Lots of content here" f = gzip.open('/home/joe/file.txt.gz', 'wb') f.write(content) f.close() If I open the gz file in 7-zip, I see a folder hierarchy matching the path I wrote the gz to and my conten...

Is there a way to do pre-compression with on-the-fly-uncompression in nginx?

It's easy to use the pre-compression module to look for a pre-compressed .gz version of a page and serve it to browsers that accept gzip to avoid the overhead of on-the-fly compression, but what I would like to do is eliminate the uncompressed version from disk and store only the compressed version, which would obviously be served the sa...

With GZIP, Can I write 'Sloppy' CSS (and other type of code) code?

The drumbeat of writing terse CSS code has been beaten into my head for years. For example: Do this: .foo,.bar{ color:#f00; } Not this: .foo{ color:#f00; } .bar{ color:#f00; } With GZIP compression isn't it irrelevant how I write the above CSS? Since GZIP will create a dynamic library with color:#...