Elgg  Version master
change_password.php
Go to the documentation of this file.
1 <?php
7 
8 $user_guid = (int) get_input('u');
9 
11 
12 // don't check code here to avoid automated attacks
13 if (!$user instanceof ElggUser) {
14  throw new EntityNotFoundException(elgg_echo('user:changepassword:unknown_user'));
15 }
16 
17 $content = elgg_view_form('user/changepassword', [
18  'class' => 'elgg-form-account',
19 ], [
20  'guid' => $user_guid,
21  'code' => get_input('c'),
22 ]);
23 
24 $shell = elgg_get_config('walled_garden') ? 'walled_garden' : 'default';
25 
26 echo elgg_view_page(elgg_echo('changepassword'), [
27  'content' => $content,
28  'sidebar' => false,
29  'filter' => false,
30 ], $shell);
elgg_view_form(string $action, array $form_vars=[], array $body_vars=[])
Definition: views.php:1033
if(!$user instanceof ElggUser) $content
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
get_input(string $variable, $default=null, bool $filter_result=true)
Parameter input functions.
Definition: input.php:20
elgg_view_page(string $title, string|array $body, string $page_shell= 'default', array $vars=[])
Assembles and outputs a full page.
Definition: views.php:235
get_user(int $guid)
Elgg users Functions to manage multiple or single users in an Elgg install.
Definition: users.php:16
$user_guid
Aggregate action for saving settings.