rcp_require_email_verification

Filters whether or not email verification is required when processing a membership registration.

Parameters:

  • $required (bool) - Whether or not email verification is required for this registration/user.
  • $posted (array) - Array of POSTed values through the registration form.
  • $user_id (int) - ID of the user making this registration.
  • $price (float) - Price of the membership the user is registering for.

Example:

This code makes it so email verification is required for registrations less than $50. Email verification is not performed if the price is greater than or equal to $50.

function ag_rcp_require_email_verification( $required, $posted, $user_id, $price ) {
	if ( $price >= 50 ) {
		return false;
	} else {
		return true;
	}
}
add_filter( 'rcp_require_email_verification', 'ag_rcp_require_email_verification', 10, 4 );