• Resolved chicodarave

    (@chicodarave)


    Hello.
    I want to show the order total, just the sum of the products values.
    How can I do this?

    Thank you very much.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Contributor Ewout

    (@pomegranate)

    In a custom template you can do that with:

    
    <?php echo $this->order->get_formatted_order_total(); ?>
    

    If you own a license for the Premium Templates you can use the {{formatted_order_total}} placeholder in a custom block in the customizer.

    Let me know if you have any other questions!
    Ewout

    Thread Starter chicodarave

    (@chicodarave)

    Hello Ewout.

    Thanks for your answer, but, I need the cart total (sum of the products) without the shipping.
    Also, I want to get it as float, I will make a comparation.

    Thank you.

    Plugin Contributor Ewout

    (@pomegranate)

    That would be:

    
    <?php $order_subtotal = $this->order->get_subtotal(); ?>
    

    Check the order abstract and order class for more methods you can use.

    Good luck!
    Ewout

    Thread Starter chicodarave

    (@chicodarave)

    Thank you very much;

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘How to show order total?’ is closed to new replies.