On the Edit profile screen in the BuddyPress profile of a user, I would like to add a new subtab that displays a form shortcode from formidable forms.
The location where I wish to add the tab for form is visible in this image: https://pasteboard.co/K4f7sQf.png
Hi Nitin,
Welcome back.Adding tab is not difficult but showing the form is not that simple. You can add a tabg with this code(or modify it to point to some other url)
add_filter( 'xprofile_filter_profile_group_tabs', function ( $tabs, $groups, $group_name ) { $link = '#'; // use your link. $label = 'My Tab'; // Add tab to end of tabs array. $tabs[] = sprintf( '<li><a href="%1$s">%2$s</a></li>', esc_url( $link ), $label ); return $tabs; }, 20, 3 );
I will suggest using a page url in the link and put your form their to make ti simple.
Regards
BrajeshI noticed you have a plugin called “BuddyPress User Profile Tabs Creator Pro”. I see that I can add a tab to the main nav and the subnav. Can it also add subtab to the profile edit screen?
I have a shortcode to display the form so if the plugin can add the subtab to profile edit screen, based on the documentation, I can just use the form shortcode in content field of the newly created tab.
Hi Nitin,
The plugin can add sub nav.The Profile Edit Group Tabs are not sub navs. They are all parts of the profile/edit sub nav. So, the Profile tabs plugin will not be of much help here.
Regards
Brajesh
The topic ‘ [Resolved] Add new subtab on edit profile screen after all field groups’ is closed to new replies.