I'm stuck trying to exclude the shipping cost from the order-totals table in the invoice email.

At the moment, the invoice email looks like this: (I included a little translation for the most important fields)

current result

As you can see: the grand total (15.80€) includes the shipping tax (6.20€).

Is it possible (and if, how) to change the grand total to exclude the shipping cost?

I've made a small mockup below:

required result

Do I need to edit template files? Or should I target the GrandTotal calculation in the model?

I'm using Magento 1.8.

I very much appreciate any help regarding this issue. :)


usually we do in the following way

do a local ovveride of app/code/core/Mage/Checkout/Block/Cart/Totals.php

and look for the function

public function renderTotal($total, $area = null, $colspan = 1)
    $code = $total->getCode();
    if ($total->getAs()) {
        $code = $total->getAs();
    if($code == 'code_to_skip')
        return(''); //does not rendere the unwanted total row
    return $this->_getTotalRenderer($code)
        ->setRenderingArea(is_null($area) ? -1 : $area)

this is the function that renders the totals to html check the $code by logging them and skip the unwanted one

hope this help

  • Does this file also render the totals in the magento invoice emails? – Pascal Raszyk Jun 17 '14 at 13:14
  • the above is for the cart, you should look into app\code\core\Mage\Sales\Block\Order – Giuseppe Jun 17 '14 at 14:33

Go To

System > configuration

In the left sidebar

Sales > Shipping Methods :

Enable Free Shipping and disable the one's that are not required

  • I can't disable it unfortunately. :( I just want to change the position of "Shipping" in the order mail. I don't know where it magento generates the HTML for the order-email totals table. – Pascal Raszyk Jun 17 '14 at 11:53
  • magento\app\design\frontend\base\default\template\checkout\onepage\review\info.phtml : This is where the design come from – TBI Infotech Jun 17 '14 at 12:03
  • I checked it. It's the table on the onepage-checkout. I tried to edit it but the order email still looks the same. :( – Pascal Raszyk Jun 17 '14 at 12:11
  • I am sorry, you want to remove this from code? Or from cart step? Do you need shipping, or you just want to comment the code fromwhere it is coming? – TBI Infotech Jun 17 '14 at 12:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.