• I am using latest version of WooCommerce and Shiprocket plugin.

    All integrations went smoothly. As soon as it is integrated and when I add product to cart, I get the following fatal error.

    Uncaught TypeError: Unsupported operand types: int * string

    A complete trace of error is as below:

    Warning: Constant WP_DEBUG_DISPLAY already defined in /var/www/cott10/wp-content/plugins/shiprocket/class-shiprocket-woocommerce-shipping.php on line 19

    Fatal error: Uncaught TypeError: Unsupported operand types: int * string in /var/www/cott10/wp-content/plugins/shiprocket/includes/class-shiprocket-woocommerce-shipping-method.php:312 Stack trace: #0 /var/www/cott10/wp-content/plugins/shiprocket/includes/class-shiprocket-woocommerce-shipping-method.php(225): Shiprocket_Woocommerce_Shipping_Method::get_formatted_data() #1 /var/www/cott10/wp-content/plugins/woocommerce/includes/abstracts/abstract-wc-shipping-method.php(257): Shiprocket_Woocommerce_Shipping_Method->calculate_shipping() #2 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-shipping.php(348): WC_Shipping_Method->get_rates_for_package() #3 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-shipping.php(260): WC_Shipping->calculate_shipping_for_package() #4 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-cart.php(1428): WC_Shipping->calculate_shipping() #5 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-cart-totals.php(346): WC_Cart->calculate_shipping() #6 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-cart-totals.php(857): WC_Cart_Totals->get_shipping_from_cart() #7 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-cart-totals.php(151): WC_Cart_Totals->calculate_shipping_totals() #8 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-cart-totals.php(141): WC_Cart_Totals->calculate() #9 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-cart.php(1406): WC_Cart_Totals->__construct() #10 /var/www/cott10/wp-includes/class-wp-hook.php(306): WC_Cart->calculate_totals() #11 /var/www/cott10/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters() #12 /var/www/cott10/wp-includes/plugin.php(517): WP_Hook->do_action() #13 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-cart.php(1284): do_action() #14 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-form-handler.php(918): WC_Cart->add_to_cart() #15 /var/www/cott10/wp-content/plugins/woocommerce/includes/class-wc-form-handler.php(790): WC_Form_Handler::add_to_cart_handler_variable() #16 /var/www/cott10/wp-includes/class-wp-hook.php(308): WC_Form_Handler::add_to_cart_action() #17 /var/www/cott10/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters() #18 /var/www/cott10/wp-includes/plugin.php(517): WP_Hook->do_action() #19 /var/www/cott10/wp-settings.php(645): do_action() #20 /var/www/cott10/wp-config.php(100): require_once(‘…’) #21 /var/www/cott10/wp-load.php(50): require_once(‘…’) #22 /var/www/cott10/wp-blog-header.php(13): require_once(‘…’) #23 /var/www/cott10/index.php(17): require(‘…’) #24 {main} thrown in /var/www/cott10/wp-content/plugins/shiprocket/includes/class-shiprocket-woocommerce-shipping-method.php on line 312

    There has been a critical error on this website.

  • The topic ‘Unsupported operand types: int * string’ is closed to new replies.