Hello @pstidsen
Thank you for your inquiry and I am happy to assist you with this.
This occurs because those files have been cached in the user’s browser from a previous visit and the cached version is served instead of the most recent version. The expiration of this cache is called time to live, or TTL and it is associated with this local cache in your browser, which is why it will show the old version until this length of time has passed. To see the correct version of the files, the user has to either clear the browser’s local cache & reload the page or do a hard refresh of the page by pressing Ctrl+F5 to ensure their browser is using the latest file versions.
When a user tries to access the URL, and the browser starts fetching the page data, it sees that it already has the page’s stylesheet E.G. style.css, and says “Wait!, I already have this file cached, so I don’t need to fetch it again and can just present that to the visitor”. And the Browser has a point!
In this case, you can use the option ” Prevent caching of objects after settings change ” in Performance>Browser Cache>CSS&JS which will add the random query string which you can update every time you make any changes to CSS or JS. something like ?xNNNNN
This will ensure that the latest version of the file is fetched by the browser and served to visitors.
Make sure to Update Media Query string (Button in the Performance>Minify or PErformance Browser Cache, just above the “General” sub-box) to ensure new version of the file is created.
Thanks!