<?php if ($this->getTotals()): ?>
<tfoot>
    <?php $_colspan = $this->helper('tax')->displayCartBothPrices() ? 5 : 3; ?>

    <?php echo $this->renderTotals(null, $_colspan); ?>
    <?php echo $this->renderTotals('footer', $_colspan); ?>
</tfoot>
<?php endif; ?>
