Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Magento get order shipping method title

Hi can anybody tell me how can i get after successfully order is placed shipping method title?

Here is what i have

$iOrderId = Mage::getSingleton('checkout/session')->getLastRealOrderId();
$oOrder = Mage::getModel('sales/order')->loadByIncrementId($iOrderId);

echo $oOrder->getShippingMethod();

but how can i get this shipping method title?

like image 778
nabizan Avatar asked Aug 26 '12 18:08

nabizan


3 Answers

$oOrder->getShippingDescription();
like image 119
ADev Avatar answered Nov 17 '22 10:11

ADev


$order = Mage::getModel('sales/order')->loadByIncrementId($iOrderId);
$order->getShippingDescription();

Or

$shipping = $order->getShippingAddress()->getShippingMethod();
echo $shipping->getData('title');
like image 22
Renon Stewart Avatar answered Nov 17 '22 10:11

Renon Stewart


This worked for me when looking for the custom title:

Mage::getModel('sales/order')->loadByIncrementId($orderId)->getTracksCollection()->getFirstItem()->getTitle();
like image 1
Christoffer Bubach Avatar answered Nov 17 '22 11:11

Christoffer Bubach