English 中文(简体)
部队浏览器复习多种资源(CSS & Javascript)
原标题:Force browser cache refresh for multiple resources (CSS & Javascript)

我正在开发一个目前正在测试阶段的网站。

电话 我对Javascript和CSS做了一些重大改动,我的测试者向我通报了许多新的 b子,其中一些是相当严重的。 然而,所有这些都由浏览器打上共同提交书和共同支助事务书,使用旧版本的超文本。 此外,由于这是一个测试版本,我有大约10份与<代码><、字母类型=“text/javascript”弧=“......>......”、&t、/script>、标的单独联合材料。 人工更新风格是可能的,但要求测试者通过每一份联合材料和复读是太多的。

是否有办法告知浏览器,相关档案已经更新,需要重新上载?

最佳回答

添加“Cache Buster”至 url, 即增加直线参数。

<script src="foo.js"></script>

......

<script src="foo.js?v=1"></script>

如果你正在准备释放,那么你就只能把释放版本作为切身车。

问题回答

如何在档案名称上添加随机示意图? 例如,时间。

style.css?123456

这将有助于。





相关问题
Write-though caching of large data sets in WCF?

We ve got a smart client that talks to a SQL Server database via WCF, displaying the entities in the database, and allowing the user to edit those entities. Some of the WCF calls return a large data ...

Clearing RSL in Cache

I have built a flex application which has a "main" project and it is assosciated with a few RSL s which are loaded and cached once i run my "main" application. The problem i am facing is that the ...

how to tell clicking "back" to load cache?

I would like for my site when someone clicks "Back" or "Forward" for the server to tell the browser to load the cache instead of reloading the entire page. I ve tested some headers and done research, ...

java plugin cache and dynamic IP host

I m trying to use Amazon S3 and Amazon Cloudfront CDN to deliver the jar files of my applet application. I m seeing several cache misses of my jars by the java plugin. This is a show-stopper for me, ...

Frequently Used metadata Hashmap

Are there any implementations of a static size hashtable that limits the entries to either the most recently or most frequently used metadata? I would prefer not to keep track of this information ...

PHP - Memcache - HTML Caching

I would like to create a caching system that will bypass some mechanisms in order to improve the performance. I have some examples: 1-) I have a dynamic PHP page that is updated every hour. The page ...

Performance of Sql subqueriesfunctions

I am currently working on a particularly complex use-case. Simplifying below :) First, a client record has a many-to-one relationship with a collection of services, that is, a single client may have ...

热门标签