|
Show messages notices error form Componet |
|
|
|
|
Written by Administrator
|
|
Wednesday, 17 February 2010 05:13 |
Show messages notices error form Componet
Messages, Errors, warnings and notices can be displayed from any component, module, plugin or template using the methods outlined below.
//Get a handle to the Joomla! application object $app =& JFactory::getApplication(); //add a message to the message queue $app->enqueueMessage( JText::_( 'Some error occurred' ), 'error' ); /** Alternatively, in PHP 5 */ JFactory::getApplication()->enqueueMessage( JText::_( 'Some error occurred' ), 'error' );
Type # 1 Message # 2 Notice # 3 Warning # 4 Error
|