• The issue here is that the AJAX add to cart feature only displays the “Product was added to your cart” message at the top of the shop page when you are within the customize screen. The product is added to the cart without reloading the page just as expected, but the feedback message is not visible. I’ve made sure that it hasn’t been hidden with CSS, and when inspecting the DOM, the container where it should appear is there, but devoid of content. Does anyone know why it only works while customizing?

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hi there,

    Would you be able to include a link to the page you’re seeing this on?

    Thank you,
    Joey

    Thread Starter saxtonstaff

    (@saxtonstaff)

    Hi,

    Here it is: http://horrordev.wpengine.com/shop/
    You won’t be able to see the “[Product] was added to your cart. View Now ->” message that appears in the customizer without admin access, but it is there.

    Thanks for the response!

    Thread Starter saxtonstaff

    (@saxtonstaff)

    @jricketts4 Any word on this?

    Hi @saxtonstaff,

    Are you redirecting to cart on ‘Add to Cart’ right now?
    I can’t test that out since I’m directly taken to the cart.

    Just let me know if you can temporarily disable that. 🙂

    Thank you,
    Joey

    Thread Starter saxtonstaff

    (@saxtonstaff)

    @jricketts4

    Oops, sorry about that! The settings must have gotten switched around while I was troubleshooting it. The cart page redirect has been turned off, and AJAX add to cart has been toggled back on.

    Hi @saxtonstaff,

    Thank you for that!

    After disabling JavaScript within the developer console, I was able to get the expected results.

    Looking at the <a> element, I see three “non”-normal jQuery events attached. They are all coming from a plugin called: pixelyoursite-pro

    Can you try disabling that to see if the notice appears as expected?

    If it does, you may want to reach out to the developers of that plugin, as it seems the functions are incorrectly disabling the add to cart process (even though the product does get added to the cart).

    Thank you,
    Joey

    Thread Starter saxtonstaff

    (@saxtonstaff)

    @jricketts4

    Still no dice. Disabling all of the plugins was something I had already tried, in fact, I even made a completely fresh WP install with only Woocommerce and one of the basic themes (maybe twentyseventeen? Not entirely sure which) and still had the issue.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘AJAX add to cart only working in customizer’ is closed to new replies.