Re:Building a currency conversion tooltip for my website
by nicbou on Friday November 25, 2022 @08:37AM
(#33742226)
I think that the page cache is set to 1 day, and dropping it to 12 hours would not strain the server. I'd just save the rates to a file on the server, and create a twig filter that wraps euro amounts with the exchange rate data. I already do this to replace constants (BLUE_CARD_MIN_INCOME) with values from a file.
However server-side generation would mean that exchange rates are cached along with the page by Google and archive.org. An old version of the page would show old exchange rates.
I care a great deal about letting users consume the content even if the website goes down, either through archive.org, Google Cache, CloudFlare, Pocket or their own archives.
However server-side generation would mean that exchange rates are cached along with the page by Google and archive.org. An old version of the page would show old exchange rates.
I care a great deal about letting users consume the content even if the website goes down, either through archive.org, Google Cache, CloudFlare, Pocket or their own archives.