无法启用 Gzip(不在共享主机上)
所以我将以下内容粘贴到我的 .htaccess (www.storyfollower.com) 中:
#Gzip
# compress the files
AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css text/javascript application/x-javascript
# removes some bugs
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4\.0[678] no-gzip
BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
Header append Vary User-Agent
#End Gzip
但是当使用 yslow 时,我得到以下内容: 压缩 http://s7.addthis.com/js/250/addthis_widget.js 可以节省 64.9KiB(减少 64%)。 压缩 http://ajax.googleapis.com/ajax/ libs/jquery/1.4.4/jquery.min.js 可以节省 50.3KiB(减少 65%)。 压缩 http://storyfollower.com/jquery.js 可以节省 50.3KiB(减少 65%)。 压缩 http://storyfollower.com/js/jquery-1.4.min.js 可以节省 45.0KiB(减少 66%)。 压缩 http://s7.addthis.com/static/r07/widget76.css 可以节省 29.4KiB(减少 78%)。 压缩 http://storyfollower.com/js/jquery.fancybox-1.2.6。使用 Node.js 可以节省 12.6KiB(减少 73%)。 压缩 http://storyfollower.com/js/jquery.autocomplete.min.js 可以节省 9.2KiB(减少 66%)。 压缩 http://storyfollower.com/js/facebox.js 可以节省 6.3KiB (69%减少)。 压缩 http://www.statcounter.com/counter/counter.js 可以节省 5.9 KiB(减少 66%)。 压缩 http://storyfollower.com/jquery.freeow.js 可以节省 3.9KiB (71%减少)。 压缩 http://storyfollower.com/js/basic.js 可以节省 3.8KiB (75%减少)。 压缩 http://storyfollower.com/css/jquery.fancybox-1.2.6。 css 可以节省 3.5KiB(减少 78%)。 压缩 http://storyfollower.com/style/freeow/freeow.css 可以节省 3.2 KiB(减少 72%)。 压缩 http://storyfollower.com/js/liteaccordion.jquery.js 可以节省 3.1 KiB(减少 64%)。 压缩http://www.youtube.com/embed/u7pTrqFU5MY?hd=1 可以节省 2.9KiB(减少 62%)。 压缩 http://storyfollower.com/css/mobile.css 可以节省 2.9KiB (70%减少)。 压缩 http://storyfollower.com/css/styles.css 可以节省 2.8KiB (71%减少)。 压缩 http://storyfollower.com/css/liteaccordion.css 可以节省 2.4KiB (69%减少)。 压缩 http://storyfollower.com/css/common.css 可以节省 1.8KiB (64%减少)。 压缩 http://storyfollower.com/js/jquery.elastic.js 可以节省 973B (减少 57%)。 压缩 http://storyfollower.com/css/facebox.css 可以节省 900B(减少 65%) )。 压缩 http://storyfollower.com/css/jquery.autocomplete.css 可以节省 359B (减少 45%)。
在 Cpanel 中启用压缩所有内容! 这也是一个专用服务器!
谢谢
so I pasted following into my .htaccess (www.storyfollower.com):
#Gzip
# compress the files
AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css text/javascript application/x-javascript
# removes some bugs
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4\.0[678] no-gzip
BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
Header append Vary User-Agent
#End Gzip
But when using yslow I get following:
Compressing http://s7.addthis.com/js/250/addthis_widget.js could save 64.9KiB (64% reduction).
Compressing http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js could save 50.3KiB (65% reduction).
Compressing http://storyfollower.com/jquery.js could save 50.3KiB (65% reduction).
Compressing http://storyfollower.com/js/jquery-1.4.min.js could save 45.0KiB (66% reduction).
Compressing http://s7.addthis.com/static/r07/widget76.css could save 29.4KiB (78% reduction).
Compressing http://storyfollower.com/js/jquery.fancybox-1.2.6.js could save 12.6KiB (73% reduction).
Compressing http://storyfollower.com/js/jquery.autocomplete.min.js could save 9.2KiB (66% reduction).
Compressing http://storyfollower.com/js/facebox.js could save 6.3KiB (69% reduction).
Compressing http://www.statcounter.com/counter/counter.js could save 5.9KiB (66% reduction).
Compressing http://storyfollower.com/jquery.freeow.js could save 3.9KiB (71% reduction).
Compressing http://storyfollower.com/js/basic.js could save 3.8KiB (75% reduction).
Compressing http://storyfollower.com/css/jquery.fancybox-1.2.6.css could save 3.5KiB (78% reduction).
Compressing http://storyfollower.com/style/freeow/freeow.css could save 3.2KiB (72% reduction).
Compressing http://storyfollower.com/js/liteaccordion.jquery.js could save 3.1KiB (64% reduction).
Compressing http://www.youtube.com/embed/u7pTrqFU5MY?hd=1 could save 2.9KiB (62% reduction).
Compressing http://storyfollower.com/css/mobile.css could save 2.9KiB (70% reduction).
Compressing http://storyfollower.com/css/styles.css could save 2.8KiB (71% reduction).
Compressing http://storyfollower.com/css/liteaccordion.css could save 2.4KiB (69% reduction).
Compressing http://storyfollower.com/css/common.css could save 1.8KiB (64% reduction).
Compressing http://storyfollower.com/js/jquery.elastic.js could save 973B (57% reduction).
Compressing http://storyfollower.com/css/facebox.css could save 900B (65% reduction).
Compressing http://storyfollower.com/css/jquery.autocomplete.css could save 359B (45% reduction).
Compress all content is enabled in Cpanel!
Also this is a dedicated Server!
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
给它一些时间...清除浏览器缓存 yslow 检查缓存的文件
Give it some time... clearing browser cache yslow checkes the cached files