Website not displaying Changes - Caching Problems
As a designer, you probably make lots of changes and Preview often. You may then do the same with Publishing or even with local Exports.
Your browser performs a thing called caching. When you visit the same web address again, it remembers your previous visits.
If you press the browser F5 key or Refresh icon, the page will reload but the cache is unaffected.
If, however, you instead press Ctrl+F5 or Hard Reset, the page is reloaded with the page's caching cleared.
You can prove this by opening the Browser Developer Tools with F12 and picking the Network tab and then pressing F5 on the original page.
The amount of data transferred should be far more if you press Ctrl+F5 rather than just F5.
Now there is a difference between Preview and local Export of a website.
In Preview, Xara invokes a built-in server and publishes to a web address like http://localhost:8000/virt<magic-number>/index.htm.
Every design Preview has its own unique <magic-number> for a given XDA session. Close the XDA, restart and there is a different <magic-number>.
Caching is mostly avoided. Xara's built-in server probably has some pragma tuning to lessen caching in the same session. Effectively, you will still get some caching until you "Switch off and on again."
For completeness, Xara "publishes" the Preview into a local filestore like %localappdata%\Local\Temp\Xara_XPSV18_18697\. You can examine your site's assets in something like the %localappdata%\Local\Temp\Xara_XPSV18_nnnnn\index_ htm_Files\ folder.
In a local Export Website, there is no server and you are seeing an address like file:///E:/Play%20area/Languages/fr/index.htm.
There should be no caching either so all changes should be apparent immediately.
There is a further difference when you Publish. Your server caches things too.
You still have browser caching but now you also have caching where your site is deployed. If you use Cloudflare, your site is sitting on edge servers thought its content delivery network (CDN). Your changes have to be send around the world.
To help, your service provider may have a capability called 'Purge Server Cache.' This clears all resources from the CDN cache in all Cloudflare data centres such that all new requests are fetched from your (recently updated) server assets.
If you are having problems, then, in order:
- Browser > Ctrl+F5.
- Recheck with a local Export.
- Check with a different Browser that has no cache or never seen the web address before.
- Disable your server CDN cache when uploading new content.
- Experiment with:
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate">
<meta http-equiv="Pragma" content="no-cache">
<meta http-equiv="Expires" content="0">
in an on-page Placeholder Code (head). Shift off-page to remove. - Check the Browser Developer Tools F12 > Network > Headers > Response Headers for assets of interest. Usually, xr_fonts.css, xr_main.css, xr_custom_styles.css & xr_text.css, affect the layout and presentation.
- Jump into your website's .htaccess file and alter the caching parameters there.
Feel free to link to this Thread when a Newbie is in trouble.
Acorn
Re: Website not displaying Changes - Caching Problems
I agree with ACORN. But I came across a problem on web hosting where they have their CACHE. So the only solution is HTACCESS - where they have to set up CACHE deletion or ask the web host to turn it off, which they don't recommend.
<IfModule mod_expires.c>
ExpiresActive On
ExpiresDefault A600
ExpiresByType text/javascript A604800
ExpiresByType application/javascript A604800
ExpiresByType text/css A604800
ExpiresByType image/gif A604800
ExpiresByType image/png A604800
ExpiresByType image/jpeg A604800
ExpiresByType image/x-icon A604800
ExpiresByType text/html A60
</IfModule>
Re: Website not displaying Changes - Caching Problems
Re: Website not displaying Changes - Caching Problems
Quote:
Originally Posted by
Acorn
...
It seems you are hosting on your local computer, If you are not publishing on the LOCAL server and if using Cloudflare DNS server, go to caching option and click on Purge all caches. And if using any cloud hosting or CDN server make sure you clear the cache from there.
Re: Website not displaying Changes - Caching Problems
Quote:
Originally Posted by
ananyaa
It seems you are hosting on your local computer, If you are not publishing on the LOCAL server and if using Cloudflare DNS server, go to caching option and click on Purge all caches. And if using any cloud hosting or CDN server make sure you clear the cache from there.
I am advised all the situations that might be encountered. The caching issue is specific to local Xara Previewing where 90% of problems are resolved with a browser cache purge. Your statement is only covering server caching. My point #4 above is more nuanced as I was proposing you do this before uploading new content as this would avoid other viewers ever seeing the mess server caching may cause.
Acorn
Re: Website not displaying Changes - Caching Problems
@xtom suggested an easier approach in this Thread: https://www.talkgraphics.com/showthr...fresh-question.
Acorn