[buddypress-trac] [BuddyPress] #2622: Function bp_get_loggedin_user_nav does not highlight active nav item
buddypress-trac at lists.automattic.com
buddypress-trac at lists.automattic.com
Tue Sep 7 19:34:17 UTC 2010
#2622: Function bp_get_loggedin_user_nav does not highlight active nav item
---------------------+------------------------------------------------------
Reporter: gzeidan | Owner:
Type: defect | Status: new
Priority: normal | Milestone: 1.3
Component: Core | Keywords:
---------------------+------------------------------------------------------
There is an error in the function bp_get_loggedin_user_nav on the file:
/buddypress/bp-core/bp-core-templatetags.php
It is missing the use of brackets while invoking the function
bp_is_directory.
See below an extract of the code:
{{{
/* Loop through each navigation item */
foreach( (array) $bp->bp_nav as $nav_item ) {
/* If the current component matches the nav item id, then
add a highlight CSS class. */
if ( !bp_is_directory &&
$bp->active_components[$bp->current_component] == $nav_item['css_id'] )
$selected = ' class="current selected"';
else
$selected = '';
}}}
After replacing "!bp_is_directory" with "!bp_is_directory()" everything
started working fine.
This error is causing the function not to highlight the active nav item
appropriately.
--
Ticket URL: <http://trac.buddypress.org/ticket/2622>
BuddyPress <http://buddypress.org/>
BuddyPress
More information about the buddypress-trac
mailing list