Elgg  Version master
content.php
Go to the documentation of this file.
1 <?php
2 
4  '#type' => 'checkbox',
5  'label' => elgg_echo('installation:walled_garden:label'),
6  '#help' => elgg_echo('installation:walled_garden:description'),
7  'name' => 'walled_garden',
8  'checked' => (bool) elgg_get_config('walled_garden'),
9  'switch' => true,
10 ]);
11 
13  '#type' => 'access',
14  'options_values' => [
15  ACCESS_PRIVATE => elgg_echo('access:label:private'),
16  ACCESS_LOGGED_IN => elgg_echo('access:label:logged_in'),
17  ACCESS_PUBLIC => elgg_echo('access:label:public'),
18  ],
19  'name' => 'default_access',
20  '#label' => elgg_echo('installation:sitepermissions'),
21  '#help' => elgg_echo('admin:site:access:warning'),
22  'value' => elgg_get_config('default_access'),
23 ]);
24 
26  '#type' => 'checkbox',
27  'label' => elgg_echo('installation:allow_user_default_access:label'),
28  '#help' => elgg_echo('installation:allow_user_default_access:description'),
29  'name' => 'allow_user_default_access',
30  'checked' => (bool) elgg_get_config('allow_user_default_access'),
31  'switch' => true,
32 ]);
33 
35  '#type' => 'number',
36  'name' => 'default_limit',
37  '#label' => elgg_echo('installation:default_limit'),
38  'value' => elgg_get_config('default_limit'),
39  'min' => 1,
40  'step' => 1,
41 ]);
42 
44  '#type' => 'select',
45  '#label' => elgg_echo('config:content:pagination_behaviour'),
46  '#help' => elgg_echo('config:content:pagination_behaviour:help'),
47  'name' => 'pagination_behaviour',
48  'value' => elgg_get_config('pagination_behaviour'),
49  'options_values' => [
50  'navigate' => elgg_echo('config:content:pagination_behaviour:navigate'),
51  'ajax-replace' => elgg_echo('config:content:pagination_behaviour:ajax-replace'),
52  'ajax-append' => elgg_echo('config:content:pagination_behaviour:ajax-append'),
53  'ajax-append-auto' => elgg_echo('config:content:pagination_behaviour:ajax-append-auto'),
54  ],
55 ]);
56 
58  '#type' => 'select',
59  '#label' => elgg_echo('config:content:mentions_display_format'),
60  '#help' => elgg_echo('config:content:mentions_display_format:help'),
61  'name' => 'mentions_display_format',
62  'value' => elgg_get_config('mentions_display_format'),
63  'options_values' => [
64  'display_name' => elgg_echo('config:content:mentions_display_format:display_name'),
65  'username' => elgg_echo('config:content:mentions_display_format:username'),
66  ],
67 ]);
68 
70  '#type' => 'checkbox',
71  '#label' => elgg_echo('config:content:trash_enabled:label'),
72  '#help' => elgg_echo('config:content:trash_enabled:help'),
73  'name' => 'trash_enabled',
74  'value' => 1,
75  'checked' => (bool) elgg_get_config('trash_enabled'),
76  'switch' => true,
77 ]);
78 
80  '#type' => 'number',
81  '#label' => elgg_echo('config:content:trash_retention:label'),
82  '#help' => elgg_echo('config:content:trash_retention:help'),
83  '#class' => ['elgg-divide-left', 'plm'],
84  'name' => 'trash_retention',
85  'value' => (int) elgg_get_config('trash_retention'),
86  'min' => 0,
87 ]);
88 
89 echo elgg_view_module('info', elgg_echo('admin:legend:content'), $body);
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.
elgg_echo(string $message_key, array $args=[], string $language= '')
Elgg language module Functions to manage language and translations.
Definition: languages.php:17
$body
Definition: content.php:3
const ACCESS_PRIVATE
Definition: constants.php:10
const ACCESS_LOGGED_IN
Definition: constants.php:11
const ACCESS_PUBLIC
Definition: constants.php:12