IE脚本打乱IIS7中使用静态COM pression开启 [英] IE scrambles script in IIS7 with static compression turned on
问题描述
我有IIS7中的JavaScript文件没有DECOM pressing不正确加载的问题和样式表。
我可以修复通过关闭IIS中的静态COM pression这个问题,但是这不能成为一个永久性的解决方案。这个问题突然开始发生。我们没有改变code。
Web应用程序是在.NET 4中一个asp.net web表单应用程序。
静态和动态融为一体pression在IIS中设置的。
另一个Web窗体的Web应用程序仍在运行罚款与静态COM pression设置在应用程序级别。
服务器更新到.NET 4.5框架。
一些标记设置为RUNAT服务器作为我追加一个版本号来强制CSS的重载其缓存和一个新的版本发布时的样式表。
这个问题只发生在Internet Explorer中。
我真的卡住这个问题。
的请求
请求GET /webapp/JavaScript/jQuery/js/jquery-1.3.2.min.js HTTP / 1.1
接受text / html的,是application / xhtml + XML,* / *
接受语言的X EN-GB-zscot
用户代理的Mozilla / 5.0(兼容; MSIE 9.0; Windows NT的6.1; Win64的; 64,三叉戟/ 5.0)
UA-CPU AMD64
接受编码gzip的,放气
主机本地主机
连接保持
响应头
核心价值
响应的HTTP / 1.1 200 OK
缓存控制私人
内容类型application / x-的javascript
内容编码的gzip,gzip的
最后修改周三,2012年10月10日15点45分44秒GMT
接受-范围字节
ETag的04f24efea6cd1:0
有所不同的Accept-Encoding
服务器Microsoft-IIS / 7.5
幽浮pressed,通过HttpCom preSS
日期星期二,2012年12月4日11时07分13秒GMT
内容长度19788
响应身体的一部分
<
@õ¿<ä½kwÚȶ(UYU
¬ÕÛ-...âá¤×&GT克+ŒtÂÛI~a²®²M7F^€ã¤ýÛï|T•ª„p²ö8çŽ;ÆéÑ1R©Þ5k¾kVéÕÿȽÊýñé)šÏµÃ¯áéh>y\\溛yI_ŠoŠ¯1Ïýrùè—Jü³GñC RñÃûøñû|rw¿Ì¹#/÷º\\þG®ßÏrŸ£AA3 | X
我已经缩小这个问题到使用本网站Blowery HttpCom pression。
这似乎与.NET 4.5 Blowery和IIS不再一起玩很好,静态内容似乎是COM $ P $由Blowery一次由IIS pssed两次,第一次。
以上是一个猜测,但人觉得我知道的是,被删除Blowery的网站再次正常工作。
I am having issues with javascript files not decompressing in IIS7 and stylesheets not loading properly.
I can fix this issue by turning off Static compression in IIS but this can't be a permanent solution. The issue has suddenly started happening. We haven't changed the code.
The web application is an asp.net web forms app in .net 4. static and dynamic compression was set in IIS. another web forms web application is still running fine with static compression set at the application level.
the server was updated to .net 4.5 framework.
Some of the stylesheets tags are set to runat server as I append a version number to force a reload of the css when its cached and a new version is released.
This issue only happens in Internet Explorer.
I am really stuck on this issue.
The Request
Request GET /webapp/JavaScript/jQuery/js/jquery-1.3.2.min.js HTTP/1.1
Accept text/html, application/xhtml+xml, */*
Accept-Language x-en-GB-zscot
User-Agent Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Win64; x64; Trident/5.0)
UA-CPU AMD64
Accept-Encoding gzip, deflate
Host localhost
Connection Keep-Alive
Response Headers
Key Value
Response HTTP/1.1 200 OK
Cache-Control private
Content-Type application/x-javascript
Content-Encoding gzip,gzip
Last-Modified Wed, 10 Oct 2012 15:45:44 GMT
Accept-Ranges bytes
ETag "04f24efea6cd1:0"
Vary Accept-Encoding
Server Microsoft-IIS/7.5
X-Compressed-By HttpCompress
Date Tue, 04 Dec 2012 11:07:13 GMT
Content-Length 19788
Part of the Response Body
‹
@õ¿‹ä½kwÚȶ(úýü
¬ÕÛ-…âá¤×>g +ŒtÂÛI~a²®²M7F^€ã¤ýÛï|T•ª„p²ö8çŽ;ÆéÑ1R©Þ5k¾kVéÕÿȽÊýñé)šÏµÃ¯áéh>y\æº"›yI_ŠoŠ¯1Ïýrùè—Jü³GñC RñÃûøñû|rw¿Ì¹#/÷º\þG®ßÏrŸ£Åä3|x
I have narrowed this issue down to the web site using Blowery HttpCompression.
It seems that with .net 4.5 Blowery and IIS no longer play together nicely and the static content seems to be compressed twice, once by Blowery and once by IIS.
The above is a guess but one think I do know is that be removing Blowery the website works fine again.
这篇关于IE脚本打乱IIS7中使用静态COM pression开启的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!