Avoid Cache-busting Plugins

Traffic spikes tend to hit one or two pages on your site, so to profit from traffic spikes you need to ensure everything is cachable and that everything is actually cached.

Pages are only cachable if they do not have unique content per user. Unique content per user includes things like:

  • Wishlist widget – if it generates the content through PHP (server-side) rather than using JavaScript/Ajax, then this is producing unique content per user and prevents page-caching
  • Basket widget – if your basket widget generates a number using PHP rather than Ajax then your pages are not cachable
  • Recently viewed products widget – if your widget generates the view of recently viewed products through PHP then the pages cannot be cached as other users would then see this users recently viewed products instead of their own

Cache-busting Plugin blacklist

This list will grow as I gather more plugins to add to the blacklist. If you are the author of one of these plugins, get in touch and I can explain how to make your plugin behave nicely with page-caching plugins.

  • Yith Wishlist – if a page is cached, the next user will see the last users wishlist
  • WooCommerce recently viewed products widget – if a page is cached, the next user sees the previous uses recently viewed products
  • Simple Ajax Chat – it spits out user-specific Javascript inside a PHP page. This means if you cache the page, the 2nd user will be able to talk to admin as if they are the first user…

If you know of any more, or have any you’d like to investigate please comment below.

 

 

Chat to me

Dave Hilditch

Founder at WP Intense
Dave has been programming since 6 years old and has been developing WordPress plugins, themes and websites since 2010. In the past he built the browse view technology for Skyscanner and now he helps clients with interesting website challenges.

He is always on at least one of his computers when he's awake, so get in touch and he'll get right back to you.
Chat to me

Latest posts by Dave Hilditch (see all)