<?php
foreach($this->getTotals() as $total)
{
if ($total->getCode() == 'subtotal')
{
$subtotal = $total->getValue();
break;
}
}
echo $subtotal;
?>
Any way to get subtotal directly ?
<?php
foreach($this->getTotals() as $total)
{
if ($total->getCode() == 'subtotal')
{
$subtotal = $total->getValue();
break;
}
}
echo $subtotal;
?>
Any way to get subtotal directly ?
The following should work:
$subtotal = $this->getQuote()->getSubtotal();