Skip to:
Content
Pages
Categories
Search
Top
Bottom

How to move Favorites subnav to nav in member page ?

  • Hi,
    I searched the forum to find some informations about this, but I couldn’t quite gather it all.

    My problem : the Favorites subnav is part of the Activity tab, in the member page. I want to emphasize it by “upping” it to the upper level, besides the Profile and the Activity tabs.

    I found about the bp_core_new_nav_item and bp_core_remove_nav_item functions, and subnav ones. So, I should remove the favorites subnav of Activity nav, and create a Favorites nav, I guess ?
    But can a nav exist without any subnav ?
    And what screen_function must I give to this new nav (or single subnav, if a nav can’t exist without subnavs) to use existing favorites page, and not a custom one ? (I just want to move it)

    I hope I’m clear, and I thank you for your help.

Viewing 1 replies (of 1 total)
  • I tried :
    `$fav_screen_function = $bp->bp_options_nav;
    bp_core_remove_subnav_item(‘activity’,’favorites’);
    bp_core_new_nav_item( array(
    ‘name’ => ‘Favoris’,
    ‘slug’ => ‘favorites’,
    ‘position’ => 20,
    ‘show_for_displayed_user’ => false,
    ‘screen_function’ => $fav_screen_function,
    ‘item_css_id’ => ‘favoris’
    ));`
    The remove subnav is ok, and the new nav Favoris is created, but it links to a page where the subnav is the nav again, and it looks quite strange… I guess I should create a subnav.

Viewing 1 replies (of 1 total)
  • The topic ‘How to move Favorites subnav to nav in member page ?’ is closed to new replies.
Skip to toolbar