How to use Buddypress xProfile field as WordPress Bio

To just answer this question.. Hope it’s okay to pull this back up ^^ <div class=”profile-bio”> <!– Profile user info bio text –> <?php if ( $string = xprofile_get_field_data( ‘About’, get_the_author_meta(‘ID’) ) ) { echo ‘<div class=”author-about”>’; echo $string; echo ‘</div>’; } ?><!– EOF Profile user info bio text –> </div> I’m also using this, … Read more

New custom nev not working [closed]

Based on the code you’ve shown, the main problem is this: bp_core_load_template( apply_filters( ‘bp_core_template_plugin’, ‘members/single/rebons’ ) ); Should be this: bp_core_load_template( apply_filters( ‘bp_core_template_plugin’, ‘members/single/plugins’ ) ); The way you are adding the nav tabs may also be a problem. Here is a gist that might help. I have created a file ribbons.php according to profile.php … Read more

Buddypress – adding custom post to members

There are more problems: 1) Add the activity on adding meeting You could use the save_post hook to add activity, but I’d rather add custom notification, as the activity item can be easily missed. The how to is described in this great tutorial https://webdevstudios.com/2015/10/06/buddypress-adding-custom-notifications/ 2) Let the users view the post You should save post_meta … Read more

Query users which have same dynamically generated roles as the current user

To achieve this, you first need to get all the current user roles, X and Y(s)… function get_current_user_roles(){ global $wp_roles; $current_user = wp_get_current_user(); $user_groups = groups_get_user_groups( $current_user->ID ); $user_roles = isset( $current_user->roles[‘X’] ) ? array( ‘X’ ) : array(); // Let’s get all Y dynamic user roles… foreach ( $user_groups[‘groups’] as $id ) { $group … Read more

Add an extra field to BuddyPress activity form

First of all, there is only 1 $accepted_args, not 3, so the add_action is: add_action(‘bp_activity_after_save’, ‘where_activity_from’, 10, 1); Second, the value in your tags input is never parsed by BP_Activity_Activity->save() so how could it be part of the array available thru the hook? Try using the $_POST array, like this: add_action(‘bp_activity_after_save’, ‘where_activity_from’, 10, 1); function … Read more

Buddypress on Multisite – Member List

BP on multisite can be quite complicated. If you network-activated BP, then afaik the users will be available on all ‘blogs’. There are several ways to config a BP > multisite install. There are a couple of plugins that may help, for example: https://buddydev.com/plugins/buddypress-multi-network/ More info from the BP codex: https://codex.buddypress.org/getting-started/installation-in-wordpress-multisite/

Buddypress function and global $bp question

Plugins load alphabetically by default. If Buddypress is alphbetically before your plugins folder name, then Buddypress will load first and it’s functions will be available. Additionally, whatever functionality depends on another plugins you can always attach to the plugins_loaded hook, which fires after all plugins are finished loading. For example: /** * Runs code after … Read more