• Hi Woo,
    It seems woocommerce_add_to_cart_fragments not working from the latest update. Whatever theme, even Storefront having this issue.

    Can you please advice as there are a lot of people creating basket count for this filter. Thanks!

Viewing 11 replies - 1 through 11 (of 11 total)
  • Hi @rplofino

    It seems woocommerce_add_to_cart_fragments not working from the latest update. Whatever theme, even Storefront having this issue.

    Can you please advice as there are a lot of people creating basket count for this filter.

    From what I understand, you’re experiencing a problem with the woocommerce_add_to_cart_fragments function after the latest update.

    To help us figure out what’s going on, could you send us a copy of your site’s System Status? This will give us a clearer picture of your site’s setup and help us pinpoint the problem. You can find it via WooCommerce > Status. Select Get system report and then Copy for support.

    Additionally, could you also provide us with the Stripe error logs (if any) under WooCommerce > Status > Logs.

    Once you’ve got that, you can paste them right here in your reply, or use https://pastebin.com/ to paste it there and share it with us.

    With this information, I’ll be able to dig deeper and come up with a more precise solution. Meanwhile, you might want to try disabling all plugins except for WooCommerce to check if the issue still occurs. This could help us see if there’s a conflict with other plugins.

    Here’s a helpful guide on how to test for conflicts: ?? How to Test for Plugin and Theme Conflicts

    Thanks for your patience and cooperation. I’m looking forward to your response. 

    Thread Starter Rommel Plofino

    (@rplofino)

    Hi Tamrat,

    Error: Missing window object: wc_cart_fragments_params. Double check if you have WooCommerce fragments enabled.

    I’ve saw similar issue from the internet.
    https://xtemos.com/forums/topic/problems-with-filter-woocommerce_add_to_cart_fragments/

    Please advice if there is a method to enable fragment if it is not by default now. I’ve experience it now from 2 of our woo websites.

    Hello, it seems this issue is related not only to 7.9.0 but also 7.8.2 at least.

    For me the issue is, that when WP Rocket caches the site, it doesn’t update the cart content counts correctly, even though I am using “WP Rocket | Deactivate WooCommerce Refresh Cart Fragments Cache” which solved the issue in older versions.

    Thread Starter Rommel Plofino

    (@rplofino)

    Hi @hovenberg,
    Yeah, I’m using WP Rocket as well and never had this issue until the recent updates.

    I believe the issue will spread like a fire when people starting noticing it. Other Woo AJAX somehow affecting as well from my issues now.

    My solution was to rollback to older version to make it worked still. But this should resolved as well for the next update. @bisratlearn

    Plugin Support Sandip Mondal – a11n

    (@sandipmondal)

    Hi everyone!

    The Cart Fragments script, responsible for updating the cart widget after a successful add-to-cart event, can cause a performance issue on stores not making use of that functionality. To mitigate this, the script will now only be enqueued if using the Mini Cart widget.

    This change was implemented with WooCommerce 7.8.

    Stores with similar functionality (e.g. from a theme) that are not using the widget can re-enable this functionality by either adding the widget to one of their widget areas/sidebars or by enqueuing the script manually:

    function enqueue_wc_cart_fragments() { wp_enqueue_script( 'wc-cart-fragments' ); }
    add_action( 'wp_enqueue_scripts', 'enqueue_wc_cart_fragments' );

    If you’re looking for an alternative to the Mini Cart widget that does not suffer from the performance issue, try the Mini Cart Block instead.

    You can read more about this change below:

    Should you have any further questions, please let me know. We are here to help!

    Thread Starter Rommel Plofino

    (@rplofino)

    Hi @sandipmondal

    Thank you for the informations. I will try that and keep you posted.

    Plugin Support Sandip Mondal – a11n

    (@sandipmondal)

    @rplofino Sounds like a plan! Do let me know how it goes! ??

    Thread Starter Rommel Plofino

    (@rplofino)

    Hi @sandipmondal ,
    It works like a charm! Thank you so much.

    Plugin Support Sandip Mondal – a11n

    (@sandipmondal)

    Hey @rplofino,

    Thanks for getting back and letting us know. I am glad to hear that!

    Should you have any further questions, please feel free to reach out. We are here to help!

    Thanks so much. I was banging my head against a wall trying to get this to work and second guessing my original development! Greatly appreciated!

    Hi @jomariet

    Thanks so much. I was banging my head against a wall trying to get this to work and second guessing my original development! Greatly appreciated!

    I’m glad to hear that the information provided was helpful and that you were able to resolve your issue! It’s very rewarding for us to know that our guidance is making a difference.

    Remember, If you ever encounter any other issues or have any other questions in the future, don’t hesitate to kick off a new topic. We’re always here to help.

    Hope you have a fantastic day!

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘woocommerce_add_to_cart_fragments not working’ is closed to new replies.