Why many buttons break under caching

A button that is added by a script in the visitor’s browser does not live in the cached page at all. It appears after the page loads, if the script loads. A button that asks the server who the visitor is, with a cookie or a login, can get the answer for the first person who visited and show it to everyone else. Neither can happen here, because the free plugin has no script and no visitor-specific data.

What the page contains

The markup of the button goes into the footer of the page, and the stylesheet link into its head. The only things in it that change from page to page are the words you wrote in the message with {title} and {url} filled in, and each page is cached on its own address, with its own title in the link.

After you change a setting

Pages that were cached before still hold the old button. Clear the cache once after saving, in your caching plugin or at your host, and every page is rebuilt with the new number, colour or side. The same goes for a number you corrected. A button that still shows the old number after you changed it is almost always a cached page.

Pro and opening hours

Opening hours depend on the moment, which a cached page cannot know. Pro solves that by deciding in the visitor’s browser, from the time on the visitor’s own device and your site’s time zone, so the cached page stays the same for everyone and the button still follows the clock. The opening hours guide explains it, with a checker.