I cannot find an answer to for several weeks. Perhaps my experience in development is not so great :) One site uses the JCH Optimize plugin and I noticed that after clearing the old memory (cache), the CSS and JS file links do not change, i.e. the names of these files remain old. The problem is that the browser checks the file name and if it has not changed, then the site visitors show the old version of the style file. The question itself, where in the plugin (in which code file) I can add some GET parameters ?vers = 1.1 so that for the browser it is a new file and it would update the information for users. I will be glad to hear any solutions. Thanks.
1 Answer
in the plugin configuration you have a button to clear JCH cache. Have you tried that? That usually does the trick for stubborn files.
-
Hi. Yes, the plugin itself has a button to clear the cache, however, as already indicated in the question itself, when you delete the cache, the plugin deletes all styles in the file. The problem is that the file name remains the same, i.e. nothing changes in the file name and browsers do not update the file for users, because if you do not change the file name, the browsers will not download the new file and they will have the old ones styles.– ArsenApr 10, 2021 at 7:35
-
I speak from memory here, but I'm pretty sure the cache button in the plugin is much more effective than the clean cache in Joomla. In my experience when cache is so persistant, using the plugin button usually fixes my issues. Have you tested it? Apr 12, 2021 at 4:30
-
Yes, of course, I tried deleting the old cache both from the plugin and through System - Clear Cache, with no results. After deleting the old cache, the data (styles) in the files are updated, however, the name of the styles file itself remains unchanged.– ArsenApr 12, 2021 at 19:04