【雪无痕网络公司】是专业青岛网站建设,青岛网站制作,青岛营销型网站建设,青岛seo,青岛网站优化公司

青岛网站建设电话:13780679218

win2003 IIS6如何一键开启GZIP压缩?

IIS6默认情况下没有开启GZIP功能,需要我们手动配置,但他又没提供图形化配置功能,一步一步配置挺麻烦的,所以从网上找了这个脚本,本人已经测试过来,运行一个多月,暂时没发现有什么问题。 

适用于自己有服务器的,安装后全站自动都启用了GZIP。 

现在基本上大站都启用GZIP了,没用过的不妨试试。 

下载:http://pan.baidu.com/s/1hsnS3UO


[code]

REM Setup IIsCompressionScheme for deflate 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcCompressionDll "%windir%\system32\inetsrv\gzip.dll" 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcCreateFlags 0 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcDoDynamicCompression TRUE 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcDoOnDemandCompression TRUE 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcDoStaticCompression TRUE 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcDynamicCompressionLevel 9 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcFileExtensions "htm" "html" "txt" "js" "xml" "css" 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcOnDemandCompLevel 9 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcPriority 1 

cscript adsutil.vbs set W3Svc/Filters/Compression/DEFLATE/HcScriptFileExtensions "asp" "dll" "exe" "aspx" "asmx" 



REM Setup IIsCompressionScheme for GZip 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcCompressionDll "%windir%\system32\inetsrv\gzip.dll" 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcCreateFlags 1 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcDoDynamicCompression TRUE 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcDoOnDemandCompression TRUE 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcDoStaticCompression TRUE 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcDynamicCompressionLevel 9 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcFileExtensions "htm" "html" "txt" "js" "xml" "css" 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcOnDemandCompLevel 9 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcPriority 1 

cscript adsutil.vbs set W3Svc/Filters/Compression/GZIP/HcScriptFileExtensions "asp" "dll" "exe" "aspx" "asmx" 


REM Setup IIsCompressionSchemes parameters 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcCacheControlHeader max-age=86400 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcCompressionBufferSize 102400 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcCompressionDirectory "%windir%\IIS Temporary Compressed Files" 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcDoDiskSpaceLimiting FALSE 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcDoDynamicCompression TRUE 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcDoOnDemandCompression TRUE 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcDoStaticCompression TRUE 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcExpiresHeader "Wed, 01 Jan 1997 12:00:00 GMT" 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcFilesDeletedPerDiskFree 256 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcIoBufferSize 102400 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcMaxDiskSpaceUsage 0 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcMaxQueueLength 1000 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcMinFileSizeForComp 1 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcNoCompressionForHttp10 FALSE 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcNoCompressionForProxies FALSE 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcNoCompressionForRange FALSE 

cscript adsutil.vbs set W3SVC/Filters/Compression/Parameters/HcSendCacheHeaders FALSE 


iisreset

[/code] 


  • 上一篇:青岛网站建设方案怎么写?
  • 下一篇:织梦dedecms文章栏目分页标题seo优化怎么设置?
  • X
    点击这里给我发消息 点击这里给我发消息 点击这里给我发消息