Why not include Requests in bp_friends_header_tabs?
-
Why is friends requests not included in bp_friends_header_tabs?
Something like this:
function bp_friends_header_tabs_plus_requests() {
global $bp, $create_group_step, $completed_to_step;
?>
<li<?php if ( !isset($bp->action_variables[0]) || 'recently-active' == $bp->action_variables[0] ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . $bp->friends->slug ?>/my-friends/recently-active"><?php _e( 'Recently Active', 'buddypress' ) ?></a></li>
<li<?php if ( 'newest' == $bp->action_variables[0] ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . $bp->friends->slug ?>/my-friends/newest"><?php _e( 'Newest', 'buddypress' ) ?></a></li>
<li<?php if ( 'alphabetically' == $bp->action_variables[0] ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . $bp->friends->slug ?>/my-friends/alphabetically""><?php _e( 'Alphabetically', 'buddypress' ) ?></a></li>
<li<?php if ( 'requests' == $bp->action_variables[0] ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . $bp->friends->slug ?>/requests"">Requests</a></li>
<?php
do_action( 'friends_header_tabs' );
}Setting the “current” for ‘Requests’ doesn’t work yet. Any ideas how to fix that?
- The topic ‘Why not include Requests in bp_friends_header_tabs?’ is closed to new replies.