• Resolved tekkidigital

    (@tekkidigital)


    Hi all,
    Suddenly the add to cart ajax isn’t working on my single product pages — but is on my variant product pages + category (archive) pages. A black square appears like it’s loading but the cart never updates / the product never adds. Thoughts?

    I’ve already troubleshooted these ways, to no avail.
    `- Disabling ALL plugins to see if it’s a compatibility issue
    – Changing the theme (in Sitehealth settings) to see if it’s a theme compatibility issue
    – Reviewed WooCommerce settings to see if there was a rouge setting in place
    – Removed custom CSS to see if there was something agitating the add to cart button
    – Reviewed WooCommerce “status” section to check for errors; none
    – Reviewed JS Console section to check for errors; none

    Lastly, I can confirm that no edits were made to code/WooCommerce settings, but I did recently update some plugins to latest verisons.

    To reproduce, simply add a single product to your cart.

    Thouuuughts?

    • This topic was modified 3 years, 5 months ago by tekkidigital.

    The page I need help with: [log in to see the link]

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Contributor royho

    (@royho)

    Hi there,

    From looking at your site, I would say it is definitely one of the two either the theme or a plugin that is conflicting or causing the issue. I know you said you tested however that is what it would appear to be.

    I see you are running WC 5.7.0 which is known to have some major issues (see other threads). You may want to rollback to 5.6.0 and disable auto updates if enabled.

    Thread Starter tekkidigital

    (@tekkidigital)

    Thanks to both of your responses. That’s also a hot tip re: WC 5.70 issues. I hadn’t heard about that. I’ll give that a go tomorrow, depending on what other folks may say overnight. Thanks, again!

    Thread Starter tekkidigital

    (@tekkidigital)

    Hey peeps, I chatted with Go Daddy and they said they think its a content incompatibility issue with the version of PHP I’m on. They also gave me this resource:

    https://uk.godaddy.com/help/view-or-change-the-php-version-for-my-linux-hosting-16090

    Still confused on how to find out what version of PHP I should be on with my (admittedly older) theme. Thoughts?

    What else is weird is that the rep was able to add single products to cart — which makes me even more confused. Ha.

    Anyways, thoughts appreciated.

    Mirko P.

    (@rainfallnixfig)

    Hey @tekkidigital,

    Thanks for getting back on the forum.

    Feel free to check out our server recommendations where we’d suggest PHP version 7.4 or greater:

    https://docs.woocommerce.com/document/server-requirements/

    You’ll see which version you’re running going to WooCommerce > Status > System Status > Server environment.

    It seems that GoDaddy has provided a guide for changing the PHP version for your Linux hosting. You can follow this guide or ask GoDaddy support to make the changes if you have any difficulties doing so.

    Thanks.

    Thread Starter tekkidigital

    (@tekkidigital)

    Sweet thanks Mirko, I’ll update to 7.4.

    I will say though, that I was having this “add to cart” ajax issue when I was on 7.8. And I rolled back to an earlier PHP to try to resolve the issue… which didn’t work. Ha.

    Any other ideas once I’ve updated to a more recent PHP? I also found some third party plugins that let you customize your add to cart buttons. Would that be a viable work around?

    :sweatsmile: Ha.

    Thread Starter tekkidigital

    (@tekkidigital)

    Can confirm I updated to 7.4 and still seeing this issue…

    hey man
    i also can’t add to cart even i was login to admin. when i click the add to cart button the number of product that i want still not appear on the cart page and it say “no product in the cart”.

    this is my website : https://winsipit.com/

    thanks

    • This reply was modified 3 years, 5 months ago by jaramiml515.
    Plugin Support abwaita a11n

    (@abwaita)

    Hi @jaramiml515,

    I visited this product page and added the item to the cart. It seems to add well and after the page refreshes, that cart item count reduces from 1 to 0. Further, each time I refresh the page, the counter on the cart goes from 1 to 0.

    As it seems that a lot is going on on that page based on the console, could you kindly perform a full conflict test to try and find the tool causing this issue. Be sure to follow all the steps outlined to be able to find the culprit.

    If the above test does not determine the cause, could you please share a copy of your site’s System Status? You can find it via WooCommerce > Status. Select “Get system report” and then “Copy for support”.? Once you’ve done that, paste it here in your response.

    Let us know how it goes.
    Thanks.

    Plugin Support abwaita a11n

    (@abwaita)

    Hi @jaramiml515,

    We’ve not heard back from you in a while, so I’m marking this thread as resolved. Hopefully, the above info was helpful and you were able to find a solution to the issue.

    If you have further questions, please feel free to open a new topic.

    Thanks.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘“Add to cart” ajax not working on single product page’ is closed to new replies.