1
我已经apache httpd的配置添加一个缓存头请求大多数静态内容:使用Apache httpd,如何为给定的UserAgent配置不缓存?
ExpiresActive On
ExpiresDefault "access plus 1 year"
# Force JNLP and BSH files to expire immediately so updates are checked for
# and seen (We need this so we see changes in the dynamic content in both)
ExpiresByType application/x-java-jnlp-file "now"
ExpiresByType application/x-bsh "now"
如何禁用此缓存,其中UserAgent
包含字符串JNLP任何要求吗?当请求来自用户代理JNLP(例如“User-Agent: JNLP/6.0 javaws/1.6.0_12 (b04) Java/1.6.0_12
”)时,我不希望任何Cache-Control
或HTTP响应中的其他与缓存相关的标头。
我可以找到基于用户代理的几件事情的配置示例,但我不知道如何配置缓存取决于用户代理。
感谢。这正是我所期待的。我在你的文章之前发现了它,然后看到了你的文章,向你发出了“正确答案”复选标记并删除了我的文章。 – Eddie 2009-02-27 23:19:47