Function __global->cns_member_validate_into_group

Definitions

sources/cns_groups_action2.php

  • Set whether a member that has applied to be in a usergroup (or is pending a promotion approval) may be in it, and inform them of the decision.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$group_id GROUP No No required parameter N/A N/A The usergroup
$prospective_member_id MEMBER No No required parameter N/A N/A The prospective member
$decline boolean No No False N/A N/A Whether the member is being declined membership
$reason string No No Blank (empty string) N/A N/A The reason given for declining

Preview

Code (PHP)

/**
 * Set whether a member that has applied to be in a usergroup (or is pending a promotion approval) may be in it, and inform them of the decision.
 *
 * @param  GROUP $group_id The usergroup
 * @param  MEMBER $prospective_member_id The prospective member
 * @param  boolean $decline Whether the member is being declined membership
 * @param  string $reason The reason given for declining
 */

function cns_member_validate_into_group(int $group_id, int $prospective_member_id, bool $decline = false, string $reason = '')