bp_get_xprofile_member_type_field_id()

Return the member type xprofile field id.

Description

Return

(string|null)

Source

File: bp-members/bp-members-functions.php

function bp_get_xprofile_member_type_field_id() {
	global $wpdb;

	$table = bp_core_get_table_prefix().'bp_xprofile_fields';
	$get_parent_id_of_member_types_field = $wpdb->get_var( $wpdb->prepare( "SELECT id FROM {$table} WHERE type = %s AND parent_id = %d ", 'membertypes', 0 ) );

	return (int) $get_parent_id_of_member_types_field;
}

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.