现在目前的问题是这样的,内网访问有gzip压缩
但是外网访问没有压缩
目前服务器可能是经过代理过来的可能和代理的设置有关
代理这部分不是我做的 所以我不是很了解
我查阅写以下相关文章,安装了iis toolkit 但是还是无解:
http://www.semcase.com/docus/iis/ref_mb_hcminfilesizeforcomp.htm
http://www.semcase.com/docus/iis/ref_mb_hcpriority.htm
http://www.codeproject.com/KB/aspnet/EnableGzip.aspx
我的配置如下:如果给大侠那个知道我是哪儿配置出了问题,还请大家多多帮忙
<IIsCompressionScheme Location ="/LM/W3SVC/Filters/Compression/deflate"
HcCompressionDll="C:\WINDOWS\system32\inetsrv\gzip.dll"
HcCreateFlags="0"
HcDoDynamicCompression="TRUE"
HcDoOnDemandCompression="TRUE"
HcDoStaticCompression="TRUE"
HcDynamicCompressionLevel="9"
HcFileExtensions="htm
html
txt
js
xml
css"
HcOnDemandCompLevel="9"
HcPriority="1"
HcScriptFileExtensions="asp
dll
exe
aspx
asmx
axd"
>
</IIsCompressionScheme>
<IIsCompressionScheme Location ="/LM/W3SVC/Filters/Compression/gzip"
HcCompressionDll="C:\WINDOWS\system32\inetsrv\gzip.dll"
HcCreateFlags="1"
HcDoDynamicCompression="TRUE"
HcDoOnDemandCompression="TRUE"
HcDoStaticCompression="TRUE"
HcDynamicCompressionLevel="9"
HcFileExtensions="htm
html
txt
js
xml
css"
HcOnDemandCompLevel="9"
HcPriority="1"
HcScriptFileExtensions="asp
dll
exe
aspx
asmx
axd"
>
</IIsCompressionScheme>
<IIsCompressionSchemes Location ="/LM/W3SVC/Filters/Compression/Parameters"
HcCacheControlHeader="max-age=86400"
HcCompressionBufferSize="102400"
HcCompressionDirectory="C:\WINDOWS\IIS Temporary Compressed Files"
HcDoDiskSpaceLimiting="FALSE"
HcDoDynamicCompression="TRUE"
HcDoOnDemandCompression="TRUE"
HcDoStaticCompression="TRUE"
HcExpiresHeader="Wed, 01 Jan 1997 12:00:00 GMT"
HcFilesDeletedPerDiskFree="256"
HcIoBufferSize="1048576"
HcMaxDiskSpaceUsage="0"
HcMaxQueueLength="1000"
HcMinFileSizeForComp="1"
HcNoCompressionForHttp10="TRUE"
HcNoCompressionForProxies="FALSE"
HcNoCompressionForRange="FALSE"
HcSendCacheHeaders="FALSE"
>
</IIsCompressionSchemes>
很简单,看一下外网访问的请求里有没有Accept-Encoding: gzip字样,如果没有的话就是代理的问题