Add to cart button stuck on loading after fixing Printful/Woo shipping conflict
-
I am trying to set up a WooCommerce store at fishdefender.org on Hostinger. I had a fatal error in class-wc-shipping.php (Call to a member function supports() on null) caused by the Printful shipping integration. The add-to-cart button gets stuck on an infinite loading spinner and never adds the item. I asked reddit and was recommended to edit shipping methods. I was able to get the site back, but the add to cart error just kept occurring. I tried deactivating everything and reinstalling. The issue came back. I tried deleting the woocommerce tables in the php database. It came back. Now product variations (size options) are also missing.
I don’t know if the root problem was the shipping method conflict or whatever cause the add to cart/AJAX error before that. At this point, I feel like I need to cut out woocommerce and printful at the root and start over entirely, but I can’t seem to do that. Every time it reinstalls, the data is already there. Please help, thanks.
Full error message from wordpress plugin menu:
An error of typeE_ERRORwas caused in line377of the file/home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-shipping.php. Error message:Uncaught Error: Call to a member function supports() on null in /home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-shipping.php:377 Stack trace: #0 /home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-shipping.php(261): WC_Shipping->calculate_shipping_for_package() #1 /home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-cart.php(1609): WC_Shipping->calculate_shipping() #2 /home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-cart-totals.php(352): WC_Cart->calculate_shipping() #3 /home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-cart-totals.php(856): WC_Cart_Totals->get_shipping_from_cart() #4 /home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-cart-totals.php(148): WC_Cart_Totals->calculate_shipping_totals() #5 /home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-cart-totals.php(138): WC_Cart_Totals->calculate() #6 /home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-cart.php(1555): WC_Cart_Totals->__construct() #7 /home/u249806196/domains/fishdefender.org/public_html/wp-content/plugins/woocommerce/includes/class-wc-cart-session.php(292): WC_Cart->calculate_totals() #8 /home/u249806196/domains/fishdefender.org/public_html/wp-includes/class-wp-hook.php(341): WC_Cart_Session->get_cart_from_session() #9 /home/u249806196/domains/fishdefender.org/public_html/wp-includes/class-wp-hook.php(365): WP_Hook->apply_filters() #10 /home/u249806196/domains/fishdefender.org/public_html/wp-includes/plugin.php(522): WP_Hook->do_action() #11 /home/u249806196/domains/fishdefender.org/public_html/wp-settings.php(764): do_action() #12 /home/u249806196/domains/fishdefender.org/public_html/wp-config.php(108): require_once('/home/u24980619...') #13 /home/u249806196/domains/fishdefender.org/public_html/wp-load.php(50): require_once('/home/u24980619...') #14 /home/u249806196/domains/fishdefender.org/public_html/wp-login.php(12): require('/home/u24980619...') #15 {main} thrownThe blog I need help with is: (visible only to logged in users)
-
Hi there,
Did you refer to fishdefender.org as the website where you’re experiencing the issue? If so, it looks like you’re using self-hosted WordPress, not WordPress.com.
https://wordpress.com/site-profiler/fishdefender.org
Therefore, it’s recommended to open a support ticket at the following URL for WordPress.org support.
https://wordpress.org/support/forums/
To understand the difference between WordPress.com and WordPress.org, please check the article below.
WordPress powers millions of websites, from bloggers and small businesses to massive news sites and companies. This guide will help you to understand the difference between WordPress.com and WordPress.org, and which might be the best fit for your website. In this guideVideo tutorialOverview of differencesComparison of featuresOverview of WordPress.comOverview of WordPress.orgFrHave a good day!
