prevent notice when sidebar blocks are not defined
This commit is contained in:
parent
cf4036104b
commit
160ce01f7b
1 changed files with 8 additions and 4 deletions
|
@ -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">
|
<div id="sidebar" class="adminBackground">
|
||||||
<?php else: ?>
|
<?php else: ?>
|
||||||
<div id="sidebar">
|
<div id="sidebar">
|
||||||
|
@ -8,9 +10,11 @@
|
||||||
<?php
|
<?php
|
||||||
echo $GLOBALS['sidebarTopMessage'].' ';
|
echo $GLOBALS['sidebarTopMessage'].' ';
|
||||||
|
|
||||||
$size = count($sidebar_blocks);
|
if (isset($sidebar_blocks) && count($sidebar_blocks)) {
|
||||||
for ($i = 0; $i < $size; $i++) {
|
$size = count($sidebar_blocks);
|
||||||
|
for ($i = 0; $i < $size; $i++) {
|
||||||
$this->includeTemplate('sidebar.block.'. $sidebar_blocks[$i]);
|
$this->includeTemplate('sidebar.block.'. $sidebar_blocks[$i]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
echo $GLOBALS['sidebarBottomMessage'];
|
echo $GLOBALS['sidebarBottomMessage'];
|
||||||
|
|
Loading…
Reference in a new issue