I need to put the value of "Grand Total without shipping and tax" into a JavaScript on the success.phtml-page. To add the Grand Total i use the following code:
<?php echo $this->__('%s', $this->escapeHtml($this->getGrandTotal())) ?>
I was thinking about using getSubtotal instead, but that will not be correct in case of any Shopping Cart Price Rule being used. So I think the approach must be something like: "GrandTotal minus shipping minus tax"
But how can I add these parameters to the code above?
EDIT: About using getSubtotal... I would then need to know how to subtract any discount given by coupon, anyone know how to do this? I was thinking about something like this:
<?php echo $this->__('%s', Mage::getModel('checkout/cart')->getQuote()->getSubtotal() - getDiscount()); ?>
...however "getDiscount()" should be something more correct..
Thanks -Espen