• Resolved emilkos

    (@emilkos-1)


    Hi,
    I use the module for calculating delivery by local carrier,but the module do not calculate shipping costs to the total.
    In the “wp-content / plugins / woocommerce / templates / order / order-details.php” I added the following code to take the amount of shipping and subtotal:

    ‘<? php $ a = array (
    get_post_meta ($ order_id, ‘Order_subtotal’, true),
    get_post_meta ($ order_id, ‘Econt_Customer_Shipping_Cost’, true));
    ?>
    <tr class = “total-cost”>
    <th> <? php _e ( ‘Total:’, ‘woocommerce’); ?> </ Th>
    <Td> <? php echo array_sum ($ a); ?> <? php echo get_woocommerce_currency_symbol (); ?> </ td>
    </ tr>’

    As a result, I get only the value of “Econt_Customer_Shipping_Cost”, but not from “Order_subtotal” to get the total.
    Please if someone can tell me what to use to get a subtotal.

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘get value from cart total or subtotal’ is closed to new replies.