prevent notice when sidebar blocks are not defined

This commit is contained in:
Christian Weiske 2011-08-17 18:16:50 +02:00
parent ec5ad71342
commit a468938a5a

View file

@ -1,4 +1,6 @@
<?php if($GLOBALS['enableAdminColors']!=false && isset($userid) && $userservice->isAdmin($userid)): ?>
<?php if ($GLOBALS['enableAdminColors'] != false
&& isset($userid) && $userservice->isAdmin($userid)
): ?>
<div id="sidebar" class="adminBackground">
<?php else: ?>
<div id="sidebar">
@ -8,10 +10,12 @@
<?php
echo $GLOBALS['sidebarTopMessage'].' ';
if (isset($sidebar_blocks) && count($sidebar_blocks)) {
$size = count($sidebar_blocks);
for ($i = 0; $i < $size; $i++) {
$this->includeTemplate('sidebar.block.'. $sidebar_blocks[$i]);
}
}
echo $GLOBALS['sidebarBottomMessage'];
?>