Sunday, July 8, 2012

Get Customer Shipping/Billing Address

$customerAddressId = Mage::getSingleton('customer/session') ->getCustomer() ->getDefaultShipping();
if ($customerAddressId)
{
$address = Mage::getModel('customer/address')->load($customerAddressId);
}
else
{
$address = Mage::getSingleton('checkout/session')->getQuote()->getShippingAddress();
}

No comments:

Post a Comment

Please mention your comments.......