Home Forums WoodMart support forum Mini cart cache issue

Mini cart cache issue

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #295513

    ToriTori38
    Participant

    Hello,

    We noticed on our site since the last major 6.0.xx update that the mini cart has a cache issue when the site is using WP Rocket. Previously WP Rocket seemed to work well with the mini-cart and the WooCommerce “cart-fragments” were cached with no issue. This I imagine really helped speed up page loads for non-logged in users.

    However since your update the mini-cart does not clear properly. For example if you delete a product from the mini cart, the mini cart count (number of items in cart graphic) does not update to show this change.

    The only work around is to install the WP Rocket plugin found here which deactivates the refresh cart fragment caching: https://docs.wp-rocket.me/article/1436-mini-cart-cached-already-has-product-in-it

    Now I undertsand the Cart Fragment issue is a long standing WooCommerce page load speed problem (talked about many times in forums!) but the question is why as of your 6.0.xx major update can WP Rocket no longer cache the refresh cart fragments like before? Something you did must have changed the way the mini cart operates. OK we have a solution, in that we have to make sure the refresh cart fragments are no longer cached (via the extra plugin I showed you), but it was a great page speed booster being able to cache those cart fragments via WP Rocket!

    Anyhow, interested to hear your thoughts. Can you also tell me how you prevent issues on your demo site. Do you have that WP Rocket plugin loaded on your test site which disables refresh cart fragment cache?

    Thanks!

    #295538

    Eric Watson
    Participant

    Hello,

    You need to install the Transients manager plugin and remove rocket_get_refreshed_fragments_cache transient there to refresh the cart widget.

    Kind Regards

    #295540

    ToriTori38
    Participant

    Hi Eric,

    Many thanks for your reply. So are you saying that once we remove the rocket_get_refreshed_fragments_cache transient, we no longer have to have that WP Rocket plugin which disables caching the refresh cart widget?

    Secondly, can we not remove these transients via the WP Rocket plugin itself (you can bulk remove transients via the WP Rocket plugin, but it does not specify what transients)?

    #295574

    Eric Watson
    Participant

    Hello,

    Removing rocket_get_refreshed_fragments_cache transient is a fix for updating the structure of the mini cart after updating the theme. And regarding the functionality of the plugin, you better contact their support.

    Kind Regards

    #295805

    ToriTori38
    Participant

    Many thanks Eric. Removing the transient data seems to have worked and I have now disabled that other plugin! Thanks for the great support 🙂

    #295831

    Eric Watson
    Participant

    Hello,

    You are welcome! If you have any questions please feel free to contact us.

    Best Regards

Viewing 6 posts - 1 through 6 (of 6 total)