8

How to get customer telephone number mentioned in order shipping address?

12
$order->getShippingAddress()->getTelephone();
4

Ganesh,you can fetch customer phone no from order shipping address by usig below code:

$orderOBject->getShippingAddress()->getTelephone();

If type of order is virtual then you does not get telephone no from shipping address.Because magento does not save shipping address for virtual order .

1

This worked for me:

$Phone = Mage::getSingleton('customer/session')->getCustomer()
    ->getPrimaryBillingAddress()
    ->getTelephone();
  • This work if you need to display on account section .for order this not work – Pratik Kamani Mar 25 '16 at 9:26

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.