I'm running a WP site with WooCommerce and I want to do some caching. I'm going to exclude the pages such as the cart/checkout for obvious reasons however there are a couple of the things on the site I would like to stay dynamic and not be cached.

An example is the number of items in the cart and there's also a block of html that displays differently whether you're logged in or not.

So my question is, should I load these via AJAX or should I define them as fragments using mfunc? What are the advantages and benefits for each and which one is recommended for this task?

  • Good question, have you found any answer for it somewhere? Thank you.
    – Marvin3
    May 12 '13 at 9:29
  • How many hits do you get on the site? Sep 10 '13 at 5:52

I'm not a friend of link only answers, but as I can't bind the whole source code + explanation in here, I'll just leave a link to @Rarst Fragment Cache Plugin.

Not the answer you're looking for? Browse other questions tagged or ask your own question.