Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/.htaccess/6.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Firefox4是否存在GZip问题?_Firefox_.htaccess_Gzip - Fatal编程技术网

Firefox4是否存在GZip问题?

Firefox4是否存在GZip问题?,firefox,.htaccess,gzip,Firefox,.htaccess,Gzip,许多人建议您在.htaccess for GZip中使用以下代码: AddOutputFilterByType DEFLATE text/html text/plain text/xml application/xml application/xhtml+xml text/javascript text/css application/x-javascript BrowserMatch ^Mozilla/4 gzip-only-text/html BrowserMatch ^Mozilla/4.

许多人建议您在.htaccess for GZip中使用以下代码:

AddOutputFilterByType DEFLATE text/html text/plain text/xml application/xml application/xhtml+xml text/javascript text/css application/x-javascript
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4.0[678] no-gzip
BrowserMatch bMSIE !no-gzip !gzip-only-text/html

为什么Firefox4需要一个例外?还是我误解了代码?

Mozilla/4
!=火狐4

事实上,作为它的一部分。出于历史兼容性原因(),大多数(所有?)web浏览器将自己标识为Mozilla(用户代理中的其他标记可用于区分Safari、Firefox和IE等)

“Mozilla/4”将与Netscape 4和IE 8或更早版本相匹配。它与任何现代网络浏览器都不匹配(IE9、所有基于Gecko的浏览器、Safari和Chrome都使用“Mozilla/5”,而Opera根本不使用“Mozilla/something”标记)