Showing posts with label Get Cart Sub total In Magento. Show all posts
Showing posts with label Get Cart Sub total In Magento. Show all posts

Wednesday, 18 December 2013

Get Sub total In Magento


Get Sub total In Magento

<div style="position:relative;bottom:5px;">
<strong>Sub Total:</strong>
<?php     $_SubtotalTax = 0;
foreach(Mage::helper('checkout/cart')->getCart()->getItems() as $item) {
$_SubtotalTax = $_SubtotalTax + $item->getTaxBeforeDiscount();
}
?>
<?php echo Mage::helper('checkout')->formatPrice(Mage::getSingleton('checkout/session')->getQuote()->getSubtotal() + $_SubtotalTax) ?>
</div>