How to turn off Etag with htaccess?

穿精又带淫゛_ 提交于 2019-12-18 19:06:49

问题


One of my friend says, etags on off mode for speed up page loading. How to off etags with htaccess?


回答1:


To unset Etags use 3 lines below:

Header unset Pragma
FileETag None
Header unset ETag 

But, to increase page loading speed, my advice is YSlow. perfect tool & Yslow recommends to use Etags instead of setting off.




回答2:


Putting the following in your .htaccess should do the trick.

Header unset ETag
FileETag None

Note: Disabling etags only helps if you are hosting the same content from more than 1 server (such as when using a cluster or CDN). Take a look at wikipedia or yahoo best practices for more information.



来源:https://stackoverflow.com/questions/5705441/how-to-turn-off-etag-with-htaccess

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!