• Resolved muzammilelahi

    (@muzammilelahi)


    I get the following error and I don’t know why.

    Warning: count(): Parameter must be an array or an object that implements Countable in /home/customer/www/staging2.humaniticharity.org/public_html/wp-content/themes/backnow-child/wpcftemplate/woocommerce/basic/include/fund-raised.php on line 17

    The code is below.

    `# Backer List Item.
    $baker_list = wpcf_function()->getCustomersByProduct();
    $total_item = 0;
    foreach($baker_list as $value){
    $order = wc_get_order($value);
    if ($order->get_status() == ‘completed’) {
    $result = count($order->get_status());
    $total_item += $result;
    }
    }`

    this is how my page looks: https://prnt.sc/vjqk3y

Viewing 1 replies (of 1 total)
  • Plugin Support RK a11n

    (@riaanknoetze)

    Hi there,

    The code there is pointing to your theme – themes/backnow-child – and isn’t something that the WooCommerce plugin itself has any direct control over. Practically speaking, you’ll want to get in touch with the developer of that child theme to take a closer look at the underlying code and possibly provide an update to make sure it’s compatible with the latest version of WooCommerce.

Viewing 1 replies (of 1 total)
  • The topic ‘woocommerce backing code error’ is closed to new replies.