How can I force a hard refresh (ctrl+F5)?

2019-01-10 19:21发布

We are actively developing a website using .Net and MVC and our testers are having fits trying to get the latest stuff to test. Every time we modify the style sheet or external javascript files, testers need to do a hard refresh (ctrl+F5 in IE) in order to see the latest stuff.

Is it possible for me to force their browsers to get the latest version of these files instead of them relying on their cached versions? We're not doing any kind of special caching from IIS or anything.

Once this goes into production, it will be hard to tell clients that they need to hard refresh in order to see the latest changes.

Thanks!

7条回答
仙女界的扛把子
2楼-- · 2019-01-10 20:00

you could edit the http headers of the files to force the browsers to revalidate on each request

查看更多
登录 后发表回答