Elgg  Version 3.0
regenerate_site_secret.php
Go to the documentation of this file.
1 <?php
2 
3 // if you cancel this even you should present a message to the user
4 if (!elgg_trigger_before_event('regenerate_site_secret', 'system')) {
5  return elgg_ok_response('', elgg_echo('admin:site:secret:prevented'));
6 }
7 
10 
11 elgg_trigger_after_event('regenerate_site_secret', 'system');
12 elgg_delete_admin_notice('weak_site_key');
13 
14 return elgg_ok_response('', elgg_echo('admin:site:secret:regenerated'));
elgg_delete_admin_notice($id)
Remove an admin notice by ID.
Definition: admin.php:71
elgg_reset_system_cache()
Reset the system cache by deleting the caches.
Definition: cache.php:24
init_site_secret()
Regenerate a new site key (32 bytes: "z" to indicate format + 186-bit key in Base64 URL)...
Definition: actions.php:93
elgg_echo($message_key, array $args=[], $language="")
Given a message key, returns an appropriately translated full-text string.
Definition: languages.php:21
elgg_trigger_before_event($event, $object_type, $object=null)
Trigger a "Before event" indicating a process is about to begin.
Definition: elgglib.php:534
elgg_ok_response($content= '', $message= '', $forward_url=null, $status_code=ELGG_HTTP_OK)
Prepares a successful response to be returned by a page or an action handler.
elgg_trigger_after_event($event, $object_type, $object=null)
Trigger an "After event" indicating a process has finished.
Definition: elgglib.php:553