Elgg  Version 6.1
users.php
Go to the documentation of this file.
1 <?php
2 
4  '#type' => 'checkbox',
5  '#label' => elgg_echo('installation:registration:label'),
6  '#help' => elgg_echo('installation:registration:description'),
7  'name' => 'allow_registration',
8  'checked' => (bool) elgg_get_config('allow_registration'),
9  'switch' => true,
10 ]);
11 
13  '#type' => 'checkbox',
14  '#label' => elgg_echo('config:users:user_joined_river'),
15  'name' => 'user_joined_river',
16  'checked' => (bool) elgg_get_config('user_joined_river'),
17  'switch' => true,
18 ]);
19 
21  '#type' => 'checkbox',
22  '#label' => elgg_echo('installation:adminvalidation:label'),
23  '#help' => elgg_echo('installation:adminvalidation:description'),
24  'name' => 'require_admin_validation',
25  'checked' => (bool) elgg_get_config('require_admin_validation'),
26  'switch' => true,
27 ]);
28 
29 $classes = ['elgg-divide-left', 'plm', 'elgg-admin-users-admin-validation-notification'];
30 if (!(bool) elgg_get_config('require_admin_validation')) {
31  $classes[] = 'hidden';
32 }
33 
35  '#type' => 'switch',
36  '#label' => elgg_echo('installation:adminvalidation:notification:label'),
37  '#help' => elgg_echo('installation:adminvalidation:notification:description'),
38  '#class' => $classes,
39  'name' => 'admin_validation_notification',
40  'value' => elgg_get_config('admin_validation_notification'),
41 ]);
42 
44  '#type' => 'number',
45  '#label' => elgg_echo('config:users:remove_unvalidated_users_days'),
46  '#help' => elgg_echo('config:users:remove_unvalidated_users_days:help'),
47  'name' => 'remove_unvalidated_users_days',
48  'value' => elgg_get_config('remove_unvalidated_users_days'),
49  'min' => 0,
50 ]);
51 
53  '#type' => 'checkbox',
54  '#label' => elgg_echo('config:users:can_change_username'),
55  '#help' => elgg_echo('config:users:can_change_username:help'),
56  'name' => 'can_change_username',
57  'checked' => (bool) elgg_get_config('can_change_username'),
58  'switch' => true,
59 ]);
60 
61 echo elgg_view_module('info', elgg_echo('admin:settings:users'), $result);
elgg_view_module(string $type, string $title, string $body, array $vars=[])
Wrapper function for the module display pattern.
Definition: views.php:919
elgg_view_field(array $params=[])
Renders a form field, usually with a wrapper element, a label, help text, etc.
Definition: views.php:1112
elgg_get_config(string $name, $default=null)
Get an Elgg configuration value.
$classes
Definition: users.php:29
elgg_echo(string $message_key, array $args=[], string $language= '')
Elgg language module Functions to manage language and translations.
Definition: languages.php:17
$result
Definition: users.php:3