bp_nouveau_get_wp_profile_fields( WP_User $user = null )

Get the WP Profile fields for all or a specific user

Description

Parameters

$user

(WP_User) (Optional) The user object. Optional.

Default value: null

Return

(array) The list of WP Profile fields

Source

File: bp-templates/bp-nouveau/includes/members/functions.php

function bp_nouveau_get_wp_profile_fields( $user = null ) {
	/**
	 * Filters the contact methods to be included in the WP Profile fields for a specific user.
	 *
	 * Provide a chance for plugins to avoid showing the contact methods they're adding on front end.
	 *
	 * @since BuddyPress 3.0.0
	 *
	 * @param array   $value Array of user contact methods.
	 * @param WP_User $user  WordPress user to get contact methods for.
	 */
	$contact_methods = (array) apply_filters( 'bp_nouveau_get_wp_profile_field', wp_get_user_contact_methods( $user ), $user );

	$wp_fields = array(
		'display_name'     => __( 'Name', 'buddyboss' ),
		'user_description' => __( 'About Me', 'buddyboss' ),
		'user_url'         => __( 'Website', 'buddyboss' ),
	);

	return array_merge( $wp_fields, $contact_methods );
}

Changelog

Changelog
Version Description
BuddyPress 3.0.0 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.