aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpete <pete@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-07-01 11:10:34 +0000
committerpete <pete@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-07-01 11:10:34 +0000
commit25ba1dd124a661d61dd4f919e928514a79e5c1a3 (patch)
tree7314417b83324420c8471c15b5ff69711fa7dbe0
parent6eadecc7aeaecd49d5f21bfabd946ddd8dbb2557 (diff)
downloadelgg-25ba1dd124a661d61dd4f919e928514a79e5c1a3.tar.gz
elgg-25ba1dd124a661d61dd4f919e928514a79e5c1a3.tar.bz2
topbar menu
git-svn-id: https://code.elgg.org/elgg/trunk@1222 36083f99-b078-4883-b0ff-0f9b5a30f544
-rw-r--r--_graphics/avatar_mini.gifbin0 -> 1125 bytes
-rw-r--r--_graphics/elgg_toolbar_logo.gifbin0 -> 1266 bytes
-rw-r--r--_graphics/elgg_toolbar_logout.gifbin0 -> 671 bytes
-rw-r--r--_graphics/toptoolbar_background.gifbin0 -> 2028 bytes
-rw-r--r--views/default/css.php254
-rw-r--r--views/default/page_elements/elgg_topbar.php90
-rw-r--r--views/default/page_elements/header.php48
7 files changed, 278 insertions, 114 deletions
diff --git a/_graphics/avatar_mini.gif b/_graphics/avatar_mini.gif
new file mode 100644
index 000000000..40b13273f
--- /dev/null
+++ b/_graphics/avatar_mini.gif
Binary files differ
diff --git a/_graphics/elgg_toolbar_logo.gif b/_graphics/elgg_toolbar_logo.gif
new file mode 100644
index 000000000..873c4e6dd
--- /dev/null
+++ b/_graphics/elgg_toolbar_logo.gif
Binary files differ
diff --git a/_graphics/elgg_toolbar_logout.gif b/_graphics/elgg_toolbar_logout.gif
new file mode 100644
index 000000000..93a86b3ed
--- /dev/null
+++ b/_graphics/elgg_toolbar_logout.gif
Binary files differ
diff --git a/_graphics/toptoolbar_background.gif b/_graphics/toptoolbar_background.gif
new file mode 100644
index 000000000..1b1166e7b
--- /dev/null
+++ b/_graphics/toptoolbar_background.gif
Binary files differ
diff --git a/views/default/css.php b/views/default/css.php
index 82fcc2597..3fe953bd5 100644
--- a/views/default/css.php
+++ b/views/default/css.php
@@ -130,6 +130,7 @@ h4 { font-size: 1.0em; }
h5 { font-size: 0.9em; }
h6 { font-size: 0.8em; }
+
/* ***************************************
PAGE LAYOUT - MAIN STRUCTURE
*************************************** */
@@ -149,7 +150,7 @@ h6 { font-size: 0.8em; }
#layout_header {
text-align:left;
- position:relative;
+ /* position:relative; */
width:100%;
height:67px;
border-bottom:1px solid #4690d6;
@@ -268,6 +269,134 @@ h6 { font-size: 0.8em; }
text-align:right;
}
+
+/* ***************************************
+ ELGG TOPBAR
+*************************************** */
+#elgg_topbar {
+ background:#333333 url(<?php echo $vars['url']; ?>_graphics/toptoolbar_background.gif) repeat-x top left;
+ color:#eeeeee;
+ border-bottom:1px solid #000000;
+ min-width:998px;
+ position:relative;
+ width:100%;
+ height:24px;
+}
+
+#elgg_topbar_container_left {
+ float:left;
+ height:24px;
+ left:0px;
+ top:0px;
+ position:absolute;
+ text-align:left;
+ width:50%;
+}
+
+#elgg_topbar_container_right {
+ float:right;
+ height:24px;
+ position:absolute;
+ right:0px;
+ top:0px;
+ width:120px;
+ text-align:right;
+}
+
+#elgg_topbar_container_search {
+ float:right;
+ height:21px;
+ width:280px;
+ position:relative;
+ right:120px;
+ text-align:right;
+ margin:3px 0 0 0;
+}
+
+#elgg_topbar_container_left .toolbarlinks,
+#elgg_topbar_container_left .toolbarimages {
+ float:left;
+}
+#elgg_topbar_container_left .toolbarlinks {
+ margin:3px 0 0 0;
+}
+#elgg_topbar_container_left .toolbarlinks a {
+ /* margin:0 0 0 20px;*/
+ color:#4690d6;
+}
+#elgg_topbar_container_left .toolbarlinks a:hover {
+ color:#eeeeee;
+}
+#elgg_topbar_container_left a.loggedinuser {
+ color:#eeeeee;
+ font-weight:bold;
+ margin:0 0 0 5px;
+}
+#elgg_topbar_container_left a.pagelinks {
+ margin:0 0 0 30px;
+}
+#elgg_topbar_container_left a.usersettings {
+ margin:0 0 0 20px;
+}
+#elgg_topbar_container_left img {
+ margin:2px 0 0 30px;
+}
+#elgg_topbar_container_right {
+ padding:4px 0 0 0;
+}
+#elgg_topbar_container_right img {
+ float:right;
+ margin:0 20px 0 0;
+ cursor:pointer;
+}
+#elgg_topbar_container_right a {
+ color:#eeeeee;
+ margin:0 5px 0 0;
+}
+
+#elgg_topbar_panel {
+ background:#333333;
+ color:#eeeeee;
+ height:200px;
+ width:100%;
+ padding:10px 20px 10px 20px;
+ display:none;
+ position:relative;
+}
+
+#searchform input.search_input {
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ background-color:#FFFFFF;
+ border:1px solid #BBBBBB;
+ color:#999999;
+ font-size:12px;
+ font-weight:bold;
+ margin:0pt;
+ padding:2px;
+ width:180px;
+
+ height:12px;
+}
+#searchform input.search_submit_button {
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ color:#ffffff;
+ background: #cccccc;
+ border:none;
+ font-size:12px;
+ font-weight:bold;
+ margin:0px;
+ padding:2px;
+ width:auto;
+ height:18px;
+ cursor:pointer;
+}
+#searchform input.search_submit_button:hover {
+ color:#000000;
+}
+
+
/* ***************************************
WIDGET PICKER (PROFILE & DASHBOARD)
*************************************** */
@@ -448,33 +577,6 @@ h6 { font-size: 0.8em; }
}
-
-/* ***************************************
- TOPMENU (IN HEADER)
-*************************************** */
-#topmenu {
- position:absolute;
- top:10px;
- right:20px;
- width: 700px;
- height:47px;
- text-align: right;
-}
-#topmenu li {
- display:inline;
- list-style:none;
-}
-#topmenu li a {
- color:#4690d6;
- margin:0 10px 0 10px;
-}
-#topmenu li a:hover {
- color:#000000;
-}
-#topmenu .usericon {
- float:right;
-}
-
/* ***************************************
COLLAPSABLE BOXES
*************************************** */
@@ -560,6 +662,7 @@ a.toggle_customise_edit_panel:hover {
margin: 0 0 0 0;
}
+
/* ***************************************
System messages
*************************************** */
@@ -582,6 +685,7 @@ a.toggle_customise_edit_panel:hover {
margin:20px 20px 0px 20px;
}
+
/* ***************************************
ELGG TOOLBAR
*************************************** */
@@ -650,6 +754,7 @@ a.toggle_customise_edit_panel:hover {
border-bottom: none;
}
+
/* ***************************************
GENERAL FORM ELEMENTS
*************************************** */
@@ -738,6 +843,7 @@ input[type="submit"] {
height: 200px;
}
+
/* ***************************************
LOGIN / REGISTER
*************************************** */
@@ -759,6 +865,7 @@ input[type="submit"] {
margin-left: 40px;
}
+
/* ***************************************
MAIN CONTENT ELEMENTS
*************************************** */
@@ -770,42 +877,6 @@ input[type="submit"] {
line-height: 1.2em;
}
-.logo {
- margin-left:21px;
- margin-top:7px;
-}
-#header_search {
- margin-right:50px;
-}
-#searchform input.search_input {
- -webkit-border-radius: 3px;
- -moz-border-radius: 3px;
- background-color:#FFFFFF;
- border:1px solid #BBBBBB;
- color:#999999;
- font-size:13px;
- font-weight:bold;
- margin:0pt;
- padding:2px;
- width:180px;
-}
-#searchform input.search_submit_button {
- -webkit-border-radius: 3px;
- -moz-border-radius: 3px;
- color:#ffffff;
- background: #cccccc;
- border:none;
- font-size:12px;
- font-weight:bold;
- margin:0px;
- padding:0px;
- width:auto;
- height:20px;
- cursor:pointer;
-}
-#searchform input.search_submit_button:hover {
- color:#000000;
-}
.widget_status_statusmessage {
font-size:1.2em;
line-height:1.2em;
@@ -821,6 +892,7 @@ input[type="submit"] {
margin:0;
}
+
/* ***************************************
PROFILE
*************************************** */
@@ -959,32 +1031,32 @@ p.user_menu_friends_of {
.search_listing_info p {
margin:0 0 3px 0;
line-height:1.2em;
-}
-
-.search_gallery_item {
- border:1px dotted silver;
- background-color: white;
- width: 210px;
- height: 200px;
-}
-
-.search_gallery_item .search_listing {
- background: none;
- text-align: center;
-}
-
-.search_gallery_item .search_listing_icon {
- position: absolute;
- margin-bottom: 20px;
-}
-
-.search_gallery_item .search_listing_info {
- margin: 5px;
-}
-
-.search_gallery_item .search_listing_info p {
- margin: 5px;
- margin-bottom: 10px;
+}
+
+.search_gallery_item {
+ border:1px dotted silver;
+ background-color: white;
+ width: 210px;
+ height: 200px;
+}
+
+.search_gallery_item .search_listing {
+ background: none;
+ text-align: center;
+}
+
+.search_gallery_item .search_listing_icon {
+ position: absolute;
+ margin-bottom: 20px;
+}
+
+.search_gallery_item .search_listing_info {
+ margin: 5px;
+}
+
+.search_gallery_item .search_listing_info p {
+ margin: 5px;
+ margin-bottom: 10px;
}
@@ -1007,6 +1079,7 @@ p.user_menu_friends_of {
color:#666666;
}
+
/* ***************************************
SPOTLIGHT
*************************************** */
@@ -1021,6 +1094,7 @@ p.user_menu_friends_of {
margin:5px 20px 5px 0;
}
+
/* ***************************************
END
*************************************** */
diff --git a/views/default/page_elements/elgg_topbar.php b/views/default/page_elements/elgg_topbar.php
new file mode 100644
index 000000000..728de79c7
--- /dev/null
+++ b/views/default/page_elements/elgg_topbar.php
@@ -0,0 +1,90 @@
+<?php
+
+ /**
+ * Elgg top toolbar
+ * The standard elgg top toolbar
+ *
+ * @package Elgg
+ * @subpackage Core
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider Ltd
+ * @copyright Curverider Ltd 2008
+ * @link http://elgg.org/
+ *
+ */
+?>
+
+<?php
+ if (isloggedin()) {
+?>
+
+<div id="elgg_topbar">
+
+<div id="elgg_topbar_container_left">
+ <div class="toolbarimages">
+ <a href=""><img src="<?php echo $vars['url']; ?>_graphics/elgg_toolbar_logo.gif" /></a>
+ <a href=""><img src="<?php echo $vars['url']; ?>_graphics/avatar_mini.gif" /></a>
+
+ <!-- new icon size needed 16px square - mini -->
+ <!--
+ <?php
+ echo elgg_view("profile/icon",array('entity' => $vars['user'], 'size' => 'mini'));
+ ?>
+ -->
+
+
+ </div>
+ <div class="toolbarlinks">
+ <a href="" class="loggedinuser">Pete</a>
+ <a href="<?php echo $vars['url']; ?>pg/dashboard/" class="pagelinks"><?php echo elgg_echo('dashboard'); ?></a>
+ <a href="" class="usersettings"><?php echo elgg_echo('settings'); ?></a>
+
+ <?php
+
+ // The administration link is for admin or site admin users only
+ if ($vars['user']->admin || $vars['user']->siteadmin) {
+
+ ?>
+
+ <a href="<?php echo $vars['url']; ?>pg/admin/" class="usersettings"><?php echo elgg_echo("admin"); ?></a>
+
+ <?php
+
+ }
+
+ ?>
+
+
+
+
+ </div>
+</div>
+
+
+<div id="elgg_topbar_container_right">
+ <img src="<?php echo $vars['url']; ?>_graphics/elgg_toolbar_logout.gif" /><a href="<?php echo $vars['url']; ?>action/logout"><small><?php echo elgg_echo('logout'); ?></small></a>
+</div>
+
+<div id="elgg_topbar_container_search">
+<form id="searchform" action="<?php echo $vars['url']; ?>search/" method="get">
+ <input type="text" size="21" name="tag" value="Search" onclick="if (this.value=='Search') { this.value='' }" class="search_input" />
+ <input type="submit" value="Go" class="search_submit_button" />
+</form>
+</div>
+
+</div><!-- /#elgg_topbar -->
+
+
+<!-- elgg user settings panel -->
+<div id="elgg_topbar_panel">
+
+<p>user settings here</p>
+
+</div>
+<!-- /#elgg_topbar_panel -->
+<div style="clear:both;"></div>
+
+<?php
+ }
+?>
+
diff --git a/views/default/page_elements/header.php b/views/default/page_elements/header.php
index 498f26d97..53f6285fb 100644
--- a/views/default/page_elements/header.php
+++ b/views/default/page_elements/header.php
@@ -24,23 +24,23 @@
$title = $vars['title'];
} else {
$title = $vars['config']->sitename . ": " . $vars['title'];
- }
-
- global $autofeed;
- if (isset($autofeed) && $autofeed == true) {
- $url = full_url();
- if (substr_count($url,'?')) {
- $url .= "&view=rss";
- } else {
- $url .= "?view=rss";
- }
- $feedref = <<<END
-
- <link rel="alternate" type="application/rss+xml" title="RSS" href="{$url}" />
-
-END;
- } else {
- $feedref = "";
+ }
+
+ global $autofeed;
+ if (isset($autofeed) && $autofeed == true) {
+ $url = full_url();
+ if (substr_count($url,'?')) {
+ $url .= "&view=rss";
+ } else {
+ $url .= "?view=rss";
+ }
+ $feedref = <<<END
+
+ <link rel="alternate" type="application/rss+xml" title="RSS" href="{$url}" />
+
+END;
+ } else {
+ $feedref = "";
}
?>
@@ -55,15 +55,17 @@ END;
<script type="text/javascript" src="<?php echo $vars['url']; ?>javascript/initialise_elgg.js"></script>
<!-- include the default css file -->
<link rel="stylesheet" href="<?php echo $vars['url']; ?>_css/css.css" type="text/css" />
- <?php
-
- echo $feedref;
- echo elgg_view('metatags',$vars);
-
+ <?php
+
+ echo $feedref;
+ echo elgg_view('metatags',$vars);
+
?>
</head>
<body>
+
+<?php echo elgg_view('page_elements/elgg_topbar', $vars); ?>
<div id="page_container">
<div id="page_wrapper">
@@ -72,7 +74,5 @@ END;
<div id="wrapper_header">
<!-- display the page title -->
<h1><a href="<?php echo $vars['url']; ?>"><?php echo $vars['config']->sitename; ?></a></h1>
- <!-- display top level navigation -->
- <?php echo elgg_view('navigation/topmenu'); ?>
</div><!-- /#wrapper_header -->
</div><!-- /#layout_header -->