diff options
Diffstat (limited to 'views/default/page/elements/messages.php')
-rw-r--r-- | views/default/page/elements/messages.php | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/views/default/page/elements/messages.php b/views/default/page/elements/messages.php new file mode 100644 index 000000000..edd40d71e --- /dev/null +++ b/views/default/page/elements/messages.php @@ -0,0 +1,27 @@ +<?php +/** + * Elgg global system message list + * Lists all system messages + * + * @package Elgg + * @subpackage Core + * + * @uses $vars['object'] The array of message registers + */ + +echo '<ul class="elgg-system-messages">'; + +// hidden li so we validate +echo '<li class="hidden"></li>'; + +if (isset($vars['object']) && is_array($vars['object']) && sizeof($vars['object']) > 0) { + foreach ($vars['object'] as $type => $list ) { + foreach ($list as $message) { + echo "<li class=\"elgg-message elgg-state-$type\">"; + echo elgg_autop($message); + echo '</li>'; + } + } +} + +echo '</ul>'; |