bp_xprofile_signup_args( array $extra = array() )

Returns xProfile loop’s signup arguments.


Parameters Parameters

$extra

(array) (Optional) extra arguments.

Default value: array()


Top ↑

Return Return

(array) The xProfile loop's signup arguments.


Source Source

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

function bp_xprofile_signup_args( $extra = array() ) {
	$signup_fields = (array) bp_xprofile_get_signup_field_ids();
	$default_args  = array(
		'fetch_fields'     => true,
		'fetch_field_data' => false,
	);

	// No signup fields? Let's bring back primary group.
	if ( ! $signup_fields && bp_is_register_page() ) {
		$default_args['profile_group_id'] = 1;
	} else {
		$default_args['signup_fields_only'] = true;
	}

	return array_merge( $default_args, $extra );
}


Top ↑

Changelog Changelog

Changelog
Version Description
8.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.