want to create a NEW tab in GROUPS bar to direct user’s to group activity page
Not sure this makes sense?
the link ‘home’ points to the activity stream for the group and is the displayed landing page by default.
@hnla Well “Home” is supposed to show a frontpage for the group, In “Activity” i want to show the activity page, that’s why i need a new tab
Ok, I found my answer:
1. Go to /wp-content/plugins/buddypress/bp-groups.php
2. After line 200, you’ll see that the nav bar items are added for Groups page
3. Then just add something like:
bp_core_new_subnav_item( array( ‘name’ => ‘Your New Tab’, ‘slug’ => ‘your-new-tab’, ‘parent_url’ => $group_link, ‘parent_slug’ => $bp->groups->slug, ‘screen_function’ => ‘your_screen_function’, ‘position’ => 11, ‘item_css_id’ => ‘home’ ) );
You can change ‘position’ integer considering that all other nav bar items have presets values of 10 multiples (10,20,30…)
Is it possible to add a class and title to the nav item for javascript application purposes?