projects
/
horde.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5cc8158
)
Add getSiteLinks()
author
Michael M Slusarz
<slusarz@curecanti.org>
Fri, 17 Jul 2009 21:15:05 +0000
(15:15 -0600)
committer
Michael M Slusarz
<slusarz@curecanti.org>
Sun, 19 Jul 2009 01:21:07 +0000
(19:21 -0600)
framework/Core/lib/Horde/Menu.php
patch
|
blob
|
history
diff --git
a/framework/Core/lib/Horde/Menu.php
b/framework/Core/lib/Horde/Menu.php
index
5e54896
..
2c9cbc4
100644
(file)
--- a/
framework/Core/lib/Horde/Menu.php
+++ b/
framework/Core/lib/Horde/Menu.php
@@
-277,14
+277,26
@@
class Horde_Menu
*/
public function addSiteLinks()
{
+ foreach ($this->getSiteLinks() as $menuitem) {
+ $this->addArray($menuitem);
+ }
+ }
+
+ /**
+ * Get the list of site links to add to the menu.
+ *
+ * @return array A list of menu items to add.
+ */
+ public function getSiteLinks()
+ {
if (is_readable($this->_menufile)) {
include $this->_menufile;
if (isset($_menu) && is_array($_menu)) {
- foreach ($_menu as $menuitem) {
- $this->addArray($menuitem);
- }
+ return $_menu;
}
}
+
+ return array();
}
/**