Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8825451
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T06:52:52+00:00 2026-06-14T06:52:52+00:00

Possible Duplicate: Css file caching I want to ensure users always get the latest

  • 0

Possible Duplicate:
Css file caching

I want to ensure users always get the latest version of my code.

However setting it up so that browsers do not cache the files is bad as it would need to be loaded fresh every page view. I want to ensure it doesn’t use a cached copy from a previous release. Eg. using a cached copy of the release 1.2 JS with version 1.3 site.

One way I have seen involves changing the filename on each release and linking to that different file name on each release (eg ‘myscript1.3.js’) This seems a lot of effort and slightly hacky.

Is there a better way to do this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T06:52:54+00:00Added an answer on June 14, 2026 at 6:52 am

    That’s a perfectly good solution, and I would even go so far as to say that it’s the best.

    You could also use query parameters to indicate a new version (?v=1, ?v=2, …). But this could throw off some public proxies (they might not cache the files). See here for details: https://developers.google.com/speed/docs/best-practices/caching#LeverageProxyCaching

    Off course this will require some effort on your part. But you can automate all of this in your deploy process (how to do that would depend entirely on your setup, so I can’t give you a solution without knowing a lot more about your project).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Possible Duplicate: CSS - percentage height I can't get the middle div of 3
Possible Duplicate: How to reference a .css file on a razor view? How to
Possible Duplicate: Adding css class through aspx code behind Im trying to assign a
Possible Duplicate: Any recommendations for a CSS minifier? I have a CSS file which
Possible Duplicate: CSS sticky footer My page has content where as users submit content,
Possible Duplicate: CSS selector case insensitive for attributes The here below code checks if
Possible Duplicate: Upload files using input type=“file” field with .change() event not always firing
Possible Duplicate: Dynamically loading an external CSS file I'm trying to create a dynamic
Possible Duplicate: css vertical centering I'm trying to get text centered in a vertical
Possible Duplicate: Create a variable in .CSS file for use within that .CSS file

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.