Prevent Your CSS and Javascript Files From Being Cached

Some websites use highly volatile, oft-changing CSS and javascript files. In the case of these files, it’s important that the developer prevent browsers from caching them. How do we do that? By using a phantom querystring, of course. We’ll use PHP to tack the current time onto the file reference. It’s a very simple technique and doesn’t affect your CSS or javascript code in any way…

VN:F [1.9.22_1171]
Rating: 0 (from 0 votes)

Leave a Reply

Your email address will not be published. Required fields are marked *