×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: PHP
Posted by: bejoy balan
Added: Sep 22, 2014 4:53 AM
Views: 203
magento display message on front end side
  1. Show Error Message in frontend
  2.  
  3. $message = $this->__(‘Email Id Already Exist.);
  4. Mage::getSingleton(‘core/session’)->addError($message);
  5. Show Success message in frontend
  6.  
  7. $message = $this->__(‘You have Register Successfully’);
  8. Mage::getSingleton(‘core/session’)->addSuccess($message);
  9.  
  10.  
  11. Show Error Message in Admin page
  12.  
  13. $message = $this->__(1 row has been updated successfully’);
  14. Mage::getSingleton(‘adminhtml/session’)->addSuccess($message);
  15. Show Success Message in Admin page
  16.  
  17. $message = $this->__(‘Email Id Already Exist.);
  18. Mage::getSingleton(adminhtml/session’)->addError($message);