Joomla error message

Saturday, July 21, 2012

print this page
send email








Have you felt like joomla default error view need to restructure.Or Want to see error in an another place>Just foolow the below code.
$app = JFactory::getApplication(); 
$queue = $app->getMessageQueue(); 
//:) which wil have you error message

if (count($queue)) { 

        echo '<aside id="message">'; 
        echo '<ul>'; 

        foreach ($queue as $item) { 
                echo '<li class="' . strtolower($item['type']) . '">'; 
                echo $item['message']; 
                echo '</li>'; 
        } 

        echo '</ul>'; 
        echo '</aside>'; 
Happy coding :)







0 comments:

Post a Comment