The following code will be helpful to get error messages in magento.
$mm = Mage::getSingleton('checkout/session');
foreach ($mm->getData('messages')->getErrors() as $item){
echo $item->getCode();
}
$mm = Mage::getSingleton('checkout/session');
foreach ($mm->getData('messages')->getErrors() as $item){
echo $item->getCode();
}
No comments:
Post a Comment