I need order totals detail like in screen shot below
I tried below code but it is not working.
$totals = $order->getTotals();
foreach ($totals as $_total) {
echo $_total->getCode() . ' => ' . $_total->getValue() . '<br />';
}
How can I achieve this?
Best Answer
If you have the order id: