25define(
'IL_REG_DISABLED', 1);
 
   26define(
'IL_REG_DIRECT', 2);
 
   27define(
'IL_REG_APPROVE', 3);
 
   28define(
'IL_REG_ACTIVATION', 4);
 
   29define(
'IL_REG_CODES', 5);
 
   31define(
'IL_REG_ROLES_FIXED', 1);
 
   32define(
'IL_REG_ROLES_EMAIL', 2);
 
   34define(
'IL_REG_ERROR_UNKNOWN', 1);
 
   35define(
'IL_REG_ERROR_NO_PERM', 2);
 
   74        $this->registration_type = 
$a_type;
 
   83        if ($ret < 1 or $ret > 5) {
 
  118        $this->password_generation_enabled = $a_status;
 
  128        $this->access_limitation = $a_access_limitation;
 
  133        $this->approve_recipient_logins = $a_rec_string;
 
  134        $this->approve_recipient_ids = array();
 
  137        foreach (explode(
',', trim($this->approve_recipient_logins)) as $login) {
 
  139                $this->approve_recipient_ids[] = $uid;
 
  149        return $this->approve_recipient_ids ? $this->approve_recipient_ids : array();
 
  153        return implode(
',', $this->unknown);
 
  171        $this->reg_hash_life_time = $a_lifetime;
 
  178        return max($this->reg_hash_life_time, self::REG_HASH_LIFETIME_MIN_VALUE);
 
  183        $this->reg_allow_codes = (bool) $a_allow_codes;
 
  195        $a_value = explode(
";", trim($a_value));
 
  196        $this->allowed_domains = $a_value;
 
  206        $this->unknown = array();
 
  207        $this->mail_perm = array();
 
  210        $login_arr = $login_arr ? $login_arr : array();
 
  211        foreach ($login_arr as $recipient) {
 
  212            if (!$recipient = trim($recipient)) {
 
  216                $this->unknown[] = $recipient;
 
  222        if (count($this->unknown)) {
 
  236        $ilias->setSetting(
'reg_role_assignment', $this->role_type);
 
  237        $ilias->setSetting(
'new_registration_type', $this->registration_type);
 
  238        $ilias->setSetting(
'passwd_reg_auto_generate', $this->password_generation_enabled);
 
  239        $ilias->setSetting(
'approve_recipient', addslashes(serialize($this->approve_recipient_ids)));
 
  240        $ilias->setSetting(
'reg_access_limitation', $this->access_limitation);
 
  241        $ilias->setSetting(
'reg_hash_life_time', $this->reg_hash_life_time);
 
  242        $ilias->setSetting(
'reg_allow_codes', $this->reg_allow_codes);
 
  243        $ilias->setSetting(
'reg_allowed_domains', implode(
';', $this->allowed_domains));
 
  255        $this->role_type = $ilias->getSetting(
'reg_role_assignment', 1);
 
  256        $this->password_generation_enabled = $ilias->getSetting(
'passwd_reg_auto_generate');
 
  257        $this->access_limitation = $ilias->getSetting(
'reg_access_limitation');
 
  258        $this->reg_hash_life_time = $ilias->getSetting(
'reg_hash_life_time');
 
  259        $this->reg_allow_codes = (bool) $ilias->getSetting(
'reg_allow_codes');
 
  261        $this->approve_recipient_ids = unserialize(stripslashes($ilias->getSetting(
'approve_recipient')));
 
  262        $this->approve_recipient_ids = $this->approve_recipient_ids ?
 
  263            $this->approve_recipient_ids :
 
  267        $tmp_logins = array();
 
  268        foreach ($this->approve_recipient_ids as 
$id) {
 
  270                $tmp_logins[] = $login;
 
  273        $this->approve_recipient_logins = implode(
',', $tmp_logins);
 
An exception for terminatinating execution or to throw for unit testing.
static _lookupLogin($a_user_id)
lookup login
static _lookupId($a_user_str)
Lookup id by login.
Class ilObjAuthSettingsGUI.
const REG_HASH_LIFETIME_MIN_VALUE
setApproveRecipientLogins($a_rec_string)
automaticRoleAssignmentEnabled()
setAccessLimitation($a_access_limitation)
setRegistrationType($a_type)
setRegistrationHashLifetime($a_lifetime)
setAllowedDomains($a_value)
static _lookupRegistrationType()
passwordGenerationEnabled()
setPasswordGenerationStatus($a_status)
getRegistrationHashLifetime()
setAllowCodes($a_allow_codes)
$approve_recipient_logins
registrationCodeRequired()
getApproveRecipientLogins()
$password_generation_enabled
if(!array_key_exists('StateId', $_REQUEST)) $id