By Jeff Suddaby on Sunday, 21 September 2014
Posted in General Issues
Likes 0
Views 894
Votes 0
Hi,

Please see attached screenshot.

How do I add and remove items from this dropdown menu?

TIA - Jeff.
Hello Jeff,

I am really sorry for the delay of this reply as it is a weekend for us here. You can actually modify the dropdown by modifying the file /components/com_easyblog/themes/default/toolbar.php file This is the block of codes responsible to output the dropdown list,


<ul class="reset-ul">
<li class="user-info">
<?php if( $system->config->get( 'toolbar_editprofile' ) ){ ?>
<a href="<?php echo EasyBlogHelper::getEditProfileLink();?>" class="avatar user-avatar float-r">
<img class="avatar" src="<?php echo $system->profile->getAvatar();?>" alt="" width="35" height="35" />
</a>
<?php } else { ?>
<a href="javascript:void(0);" class="avatar user-avatar float-r">
<img class="avatar" src="<?php echo $system->profile->getAvatar();?>" alt="" width="35" height="35" />
</a>
<?php } ?>
<div class="dashboard-user">
<a href="<?php echo $system->profile->getProfileLink(); ?>" class="user-name"><?php echo $system->profile->getName();?></a>
<?php if( $system->config->get( 'toolbar_editprofile' ) ){ ?>
<br />
<a href="<?php echo EasyBlogHelper::getEditProfileLink();?>" class="fss"><?php echo JText::_( 'COM_EASYBLOG_TOOLBAR_DASHBOARD_EDIT_PROFILE' );?></a>
<?php } ?>
</div>
</li>
<?php if(($acl->rules->publish_entry) || ($acl->rules->add_entry) || ($acl->rules->delete_entry)) { ?>
<li class="user-blogs"><a href="<?php echo EasyBlogRouter::_('index.php?option=com_easyblog&view=dashboard&layout=entries'); ?>"><?php echo JText::_('COM_EASYBLOG_TOOLBAR_DASHBOARD_ENTRIES');?></a></li>
<?php } ?>
<?php if(($acl->rules->add_entry)) { ?>
<li class="user-blogs"><a href="<?php echo EasyBlogRouter::_('index.php?option=com_easyblog&view=dashboard&layout=review'); ?>"><?php echo JText::_('COM_EASYBLOG_DASHBOARD_TOOLBAR_REVIEW');?></a></li>
<?php } ?>
<?php if($acl->rules->manage_comment && EasyBlogHelper::getHelper( 'Comment')->isBuiltin() ) : ?>
<li class="user-comments">
<a href="<?php echo EasyBlogRouter::_('index.php?option=com_easyblog&view=dashboard&layout=comments'); ?>">
<?php echo JText::_('COM_EASYBLOG_TOOLBAR_DASHBOARD_COMMENTS'); if($totalModComment > 0) { echo '<sup>' . $totalModComment. '</sup>'; } ?>
</a>
</li>
<?php endif; ?>
<?php if($acl->rules->create_category) : ?>
<li class="categories"><a href="<?php echo EasyBlogRouter::_('index.php?option=com_easyblog&view=dashboard&layout=categories'); ?>"><?php echo JText::_('COM_EASYBLOG_TOOLBAR_DASHBOARD_CATEGORIES');?></a></li>
<?php endif; ?>
<?php if($acl->rules->create_tag) : ?>
<li class="tags has_separator"><a href="<?php echo EasyBlogRouter::_('index.php?option=com_easyblog&view=dashboard&layout=tags'); ?>"><?php echo JText::_('COM_EASYBLOG_TOOLBAR_DASHBOARD_TAGS');?></a></li>
<?php endif; ?>

<li class="tags has_separator"><a href="<?php echo EasyBlogRouter::_('index.php?option=com_easyblog&view=subscription'); ?>"><?php echo JText::_('COM_EASYBLOG_TOOLBAR_DASHBOARD_SUBSCRIPTION');?></a></li>

<?php if($isTeamAdmin) : ?>
<li class="teamblogs has_separator">
<a class="blog" href="<?php echo EasyBlogRouter::_('index.php?option=com_easyblog&view=dashboard&layout=teamblogs'); ?>">
<?php echo JText::_('COM_EASYBLOG_TOOLBAR_DASHBOARD_TEAMBLOG_REQUESTS'); ?>
<?php echo ($totalTeamRequest > 0) ? '<sup>' . $totalTeamRequest . '</sup>' : '' ?>
</a>
</li>
<?php endif; ?>

<?php if( $system->config->get( 'toolbar_logout') ){ ?>
<li class="sign-out">
<form id="eblog-logout" action="<?php echo EasyBlogRouter::_( 'index.php?option=com_easyblog' );?>">
<a class="logout" href="javascript:eblog.dashboard.logout();"><?php echo JText::_( 'COM_EASYBLOG_TOOLBAR_DASHBOARD_LOGOUT' );?></a>
<?php if( EasyBlogHelper::getJoomlaVersion() >= '1.6' ){ ?>
<input type="hidden" value="com_users" name="option">
<input type="hidden" value="user.logout" name="task">
<input type="hidden" value="<?php echo $logoutURL; ?>" name="return">
<?php } else { ?>
<input type="hidden" value="com_user" name="option">
<input type="hidden" value="logout" name="task">
<input type="hidden" value="<?php echo $logoutURL; ?>" name="return">
<?php } ?>
<?php echo JHTML::_( 'form.token' ); ?>
</form>
</li>
<?php } ?>
</ul>


Hope this helps!
·
Monday, 22 September 2014 01:41
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks Mark. Just what I needed! - Jeff.
·
Monday, 22 September 2014 03:00
·
0 Likes
·
0 Votes
·
0 Comments
·
You are most welcome Jeff
·
Monday, 22 September 2014 12:16
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post