Skip to:
Content
Pages
Categories
Search
Top
Bottom

bp_core_remove_nav_item

Viewing 3 replies - 1 through 3 (of 3 total)

  • muskokee
    Participant

    @muskokee

    Like the other poster, I have used css to hide the items for now. Hopefully that is not the only thing I can do because the items I want to remove from the list are only available for paid members. Changing the css is too simple to make this secure.


    danbp
    Moderator

    @danbp

    Hi @muskokee,
    BP nav menu code is in bp-core-template.php:3050 to EOF.

    To change the position of an item on profiles page, use this from within bp-custom.php
    Position is defined by the numeric value:

    function bpfr_profile_menu_tab_pos(){
    global $bp;
    $bp->bp_nav['activity']['position'] = 30;
    $bp->bp_nav['forums']['position'] = 50;
    $bp->bp_nav['profile']['position'] = 25;
    $bp->bp_nav['messages']['position'] = 10;
    $bp->bp_nav['notifications']['position'] = 40;
    $bp->bp_nav['friends']['position'] = 20;
    $bp->bp_nav['groups']['position'] = 60;
    }
    add_action('bp_setup_nav', 'bpfr_profile_menu_tab_pos', 100);

    You can also add some condition on the template. Ie

    if ( is_user_logged_in() ) :
       your custom menu stuff
    else
       something for non logged user
    endif;

    Other reference: https://codex.buddypress.org/themes/members-navigation-menus/


    muskokee
    Participant

    @muskokee

    Thanks @danbp!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘bp_core_remove_nav_item’ is closed to new replies.
Skip to toolbar