I'm trying to change the code for the top bar of my site so that only certain active plugins appear and other active plugins remain hidden. How can i accomplish this. at present my code is;
<?php
/**
* Elgg standard tools drop down
* This will be populated depending on the plugins active - only plugin navigation will appear here
*
* @package Elgg
* @subpackage Core
* @author Curverider Ltd
* @link http://elgg.org/
*
*/
$menu = get_register('menu');
//var_export($menu);
if (is_array($menu) && sizeof($menu) > 0) {
$alphamenu = array();
foreach($menu as $item) {
$alphamenu[$item->name] = $item;
}
ksort($alphamenu);
?>
<ul id="nav">
<?php
foreach($alphamenu as $item) {
echo "<li><h1><a href=\"{$item->value}\">" . $item->name . "</a></h1></li>";
}
?>
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by RaĆ¼l Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.
- RPGRealms@quiklink
RPGRealms - 0 likes
- Shouvik Mukherjee@shouvik
Shouvik Mukherjee - 0 likes
You must log in to post replies.Go to the plugin's start file that you don't want to appear and comment out the add_menu call.
Or, create a custom dropdown menu. Replace the tools code with this one on /views/default/navigation/topbar_tools.php/