bp_nouveau_customizer_user_profile_actions()

Return profile header buttons

Description

Return

(mixed|void)

Source

File: bp-templates/bp-nouveau/includes/customizer.php

function bp_nouveau_customizer_user_profile_actions() {

	$buttons = array();

	if ( bp_is_active( 'friends' ) ) {
		$buttons['member_friendship'] = __( 'Connect', 'buddyboss' );
	}

	if ( bp_is_active( 'activity' ) && bp_is_activity_follow_active() ) { // add follow button
		$buttons['member_follow'] = __( 'Follow', 'buddyboss' );
	}

	$bp_force_friendship_to_message = bp_force_friendship_to_message();

	if ( bp_is_active( 'messages' )
	     && ( ! $bp_force_friendship_to_message
	          || ( $bp_force_friendship_to_message && bp_is_active( 'friends' ) ) )
	) {
		$buttons['private_message'] = __( 'Message', 'buddyboss' );
	}

	//Member switch button
	$buttons['member_switch'] = __( 'View As', 'buddyboss' );

	$buttons = apply_filters( 'bp_nouveau_customizer_user_profile_actions', $buttons );

	return $buttons;
}

Changelog

Changelog
Version Description
BuddyBoss 1.5.1 Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.