diff options
Diffstat (limited to 'views/default/page')
-rw-r--r-- | views/default/page/elements/body.php | 8 | ||||
-rw-r--r-- | views/default/page/elements/footer.php | 16 | ||||
-rw-r--r-- | views/default/page/elements/header.php | 27 | ||||
-rw-r--r-- | views/default/page/elements/messages.php | 9 | ||||
-rw-r--r-- | views/default/page/elements/topbar.php | 9 | ||||
-rw-r--r-- | views/default/page/shells/admin.php | 1 | ||||
-rw-r--r-- | views/default/page/shells/default.php | 5 |
7 files changed, 32 insertions, 43 deletions
diff --git a/views/default/page/elements/body.php b/views/default/page/elements/body.php index 6f7691693..31fe24ab4 100644 --- a/views/default/page/elements/body.php +++ b/views/default/page/elements/body.php @@ -5,10 +5,4 @@ * @uses $vars['body'] The HTML of the page body */ -$body = elgg_get_array_value('body', $vars, ''); - -echo <<<HTML -<div class="elgg-page-body"> - $body -</div> -HTML; +echo elgg_get_array_value('body', $vars, '');
\ No newline at end of file diff --git a/views/default/page/elements/footer.php b/views/default/page/elements/footer.php index 0c32e5429..001d856b1 100644 --- a/views/default/page/elements/footer.php +++ b/views/default/page/elements/footer.php @@ -8,15 +8,11 @@ * */ +echo elgg_view_menu('footer', array('class' => 'elgg-menu-footer')); +echo elgg_view('footer/links'); + ?> -<div class="elgg-page-footer"> - <div class="elgg-inner clearfix"> - <?php echo elgg_view_menu('footer', array('class' => 'elgg-menu-footer')); ?> - <?php echo elgg_view('footer/links'); ?> - <a href="http://www.elgg.org" class="elgg-alt"> - <img src="<?php echo elgg_get_site_url(); ?>_graphics/powered_by_elgg_badge_drk_bckgnd.gif" alt="Powered by Elgg" /> - </a> - </div> -</div> -<?php echo elgg_view('footer/analytics'); ?> +<a href="http://www.elgg.org" class="elgg-alt"> + <img src="<?php echo elgg_get_site_url(); ?>_graphics/powered_by_elgg_badge_drk_bckgnd.gif" alt="Powered by Elgg" /> +</a> diff --git a/views/default/page/elements/header.php b/views/default/page/elements/header.php index 125d80bfa..972c90272 100644 --- a/views/default/page/elements/header.php +++ b/views/default/page/elements/header.php @@ -4,21 +4,14 @@ * This file holds the header output that a user will see **/ -?> -<div class="elgg-page-header"> - <div class="elgg-inner"> - <?php - // link back to main site. - echo elgg_view('page/elements/header_logo', $vars); - - // drop-down login - echo elgg_view('core/account/login_dropdown'); - - // insert site-wide navigation - echo elgg_view_menu('site'); +// link back to main site. +echo elgg_view('page/elements/header_logo', $vars); - // insert a view which can be extended - echo elgg_view('header/extend'); - ?> - </div> -</div> +// drop-down login +echo elgg_view('core/account/login_dropdown'); + +// insert site-wide navigation +echo elgg_view_menu('site'); + +// insert a view which can be extended +echo elgg_view('header/extend'); diff --git a/views/default/page/elements/messages.php b/views/default/page/elements/messages.php index 3663bb796..e4e6030f1 100644 --- a/views/default/page/elements/messages.php +++ b/views/default/page/elements/messages.php @@ -9,10 +9,9 @@ * @uses $vars['object'] The array of message registers */ -if (isset($vars['object']) && is_array($vars['object']) && sizeof($vars['object']) > 0) { - - echo '<ul class="elgg-system-messages">'; +echo '<ul class="elgg-system-messages">'; +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\">"; @@ -23,6 +22,6 @@ if (isset($vars['object']) && is_array($vars['object']) && sizeof($vars['object' echo '</li>'; } } - - echo '</ul>'; } + +echo '</ul>'; diff --git a/views/default/page/elements/topbar.php b/views/default/page/elements/topbar.php index 7ca8a58e2..987326119 100644 --- a/views/default/page/elements/topbar.php +++ b/views/default/page/elements/topbar.php @@ -5,10 +5,8 @@ */ $user = elgg_get_logged_in_user_entity(); -if (!elgg_instanceof($user, 'user')) { - // do not show tobpar to logged out users - return true; -} + +//@todo echo elgg_view_menu('topbar', array('class' => 'elgg-menu-topbar')); // Elgg logo $image = '<img src="' . elgg_get_site_url() . '_graphics/elgg_toolbar_logo.gif" alt="Elgg logo" />'; @@ -43,11 +41,14 @@ echo elgg_view('output/url', array( // elgg tools menu // need to echo this empty view for backward compatibility. +// @todo -- do we really? So much else is broken, and the new menu system is so much nicer... echo elgg_view("navigation/topbar_tools"); // enable elgg topbar extending echo elgg_view('elgg_topbar/extend', $vars); +//@todo echo elgg_view_menu('topbar2', array('class' => 'elgg-menu-topbar elgg-alt')); + // user settings echo elgg_view('output/url', array( 'href' => elgg_get_site_url() . "pg/settings/user/{$user->username}", diff --git a/views/default/page/shells/admin.php b/views/default/page/shells/admin.php index f401f3416..211bd4037 100644 --- a/views/default/page/shells/admin.php +++ b/views/default/page/shells/admin.php @@ -22,6 +22,7 @@ header("Content-type: text/html; charset=UTF-8"); <div class="elgg-page elgg-page-admin"> <?php echo $vars['body']; ?> </div> + <?php echo elgg_view('footer/analytics'); ?> </body> </html>
\ No newline at end of file diff --git a/views/default/page/shells/default.php b/views/default/page/shells/default.php index e089d11b6..775eb4acc 100644 --- a/views/default/page/shells/default.php +++ b/views/default/page/shells/default.php @@ -35,11 +35,15 @@ header("Content-type: text/html; charset=UTF-8"); <div class="elgg-page-messages"> <?php echo elgg_view('page/elements/messages', array('object' => $vars['sysmessages'])); ?> </div> + + <?php if (elgg_is_logged_in()): ?> <div class="elgg-page-topbar"> <div class="elgg-inner"> <?php echo elgg_view('page/elements/topbar', $vars); ?> </div> </div> + <?php endif; ?> + <div class="elgg-page-header"> <div class="elgg-inner"> <?php echo elgg_view('page/elements/header', $vars); ?> @@ -56,5 +60,6 @@ header("Content-type: text/html; charset=UTF-8"); </div> </div> </div> +<?php echo elgg_view('footer/analytics'); ?> </body> </html>
\ No newline at end of file |