apache 2.0下设置了gzip,defalte压缩。发现对win2003的IE,firefox都没有作用。用IE下的httpwatch监视http协议得到:
在winxp sp2 IE6 下的http头,
发送有Accept-Encoding gzip, deflate
返回也有 Content-Encoding gzip,长度只有39k
发送:
GET /res/js/tinymce/tiny_mce.js HTTP/1.1
Accept */*
Accept-Encoding gzip, deflate
Accept-Language zh-cn
Connection Keep-Alive
Host
www.seekpai.com
User-Agent Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 2.0.50727)
应答:
HTTP/1.0 200 OK
Accept-Ranges bytes
Cache-Control max-age=2592000
Connection close
Content-Encoding gzip
Content-Length 39344
Content-Type application/x-javascript
Date Wed, 11 Apr 2007 03:06:47 GMT
ETag "21-24011-429590191c080"
Expires Fri, 11 May 2007 03:06:47 GMT
Last-Modified Tue, 13 Feb 2007 10:22:42 GMT
Server Apache
win2003 sp1 IE6下
发送有:Accept-Encoding: gzip, deflate
返回没有:gzip压缩的选项,长度是147k
发送:
GET /res/js/tinymce/tiny_mce.js HTTP/1.1
Accept: */*
Accept-Language: zh-cn
UA-CPU: x86
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.2; SV1; .NET CLR 1.1.4322)
Connection: Keep-Alive
返回:
HTTP/1.0 200 OK
Date: Wed, 11 Apr 2007 03:07:08 GMT
Server: Apache
Last-Modified: Tue, 13 Feb 2007 10:22:42 GMT
ETag: "21-24011-429590191c080"
Accept-Ranges: bytes
Content-Length: 147473
Cache-Control: max-age=2592000
Expires: Fri, 11 May 2007 03:07:08 GMT
Connection: close
Content-Type: application/x-javascript
firefox下用firebug调试,
得到的情况也是如此,2003下发送有 Accept-Encoding gzip,deflate
但返回还是没有压缩,长度是147k
User-Agent Mozilla/5.0 (Windows; U; Windows NT 5.2; zh-CN; rv:1.8.1.3) Gecko/20070309 Firefox/2.0.0.3
Accept */*
Accept-Language zh-cn,zh;q=0.5
Accept-Encoding gzip,deflate
Accept-Charset gb2312,utf-8;q=0.7,*;q=0.7
Keep-Alive 300
Connection keep-alive
Date Wed, 11 Apr 2007 05:31:37 GMT
Server Apache
Last-Modified Tue, 13 Feb 2007 10:22:42 GMT
Etag "21-24011-429590191c080"
Accept-Ranges bytes
Content-Length 147473
Cache-Control max-age=2592000
Expires Fri, 11 May 2007 05:31:37 GMT
Connection close
Content-Type application/x-javascript
找了一下资料,只是说在HTTP头中,winxp 核心编号是 NT 5.1, 而2003的核心编号是 NT 5.2。