Elgg  Version 5.1
Go to the documentation of this file.
1 <?php
12 $entity_guid = (int) elgg_extract('entity_guid', $vars);
14  throw new EntityNotFoundException();
15 }
17 $recipient_guid = (int) elgg_extract('recipient_guid', $vars);
22 $actor_guid = (int) get_input('actor_guid', elgg_extract('actor_guid', $vars));
25 elgg()->translator->setCurrentLanguage($recipient->getLanguage());
27 // using ignored access to be abe to show non public content
32  return elgg_view_form('notifications/mute', [], [
33  'entity' => $entity,
34  'recipient' => $recipient,
35  'actor' => $actor,
36  ]);
37 });
39 if (empty($content)) {
40  throw new EntityNotFoundException(elgg_echo('notifications:mute:error:content'));
41 }
43 echo elgg_view_page(elgg_echo('notifications:mute:title'), [
44  'content' => $content,
45  'filter_id' => 'notifications',
46  'filter_value' => 'mute',
47  'show_owner_block_menu' => false,
48 ]);
elgg_call(int $flags, Closure $closure)
Calls a callable autowiring the arguments using public DI services and applying logic based on flags...
Definition: elgglib.php:299
elgg_view_form(string $action, array $form_vars=[], array $body_vars=[])
Definition: views.php:1054
if(($owner instanceof\ElggGroup||$owner instanceof\ElggUser)&&!in_array($owner->guid, $mute_guids)) $actor
Definition: mute.php:86
Definition: mute.php:22
elgg_entity_gatekeeper(int $guid, string $type=null, string $subtype=null, bool $validate_can_edit=false)
Can the viewer see this entity?
Definition: gatekeepers.php:99
Definition: mute.php:12
elgg_echo(string $message_key, array $args=[], string $language= '')
Elgg language module Functions to manage language and translations.
Definition: languages.php:17
Definition: mute.php:28
elgg_set_page_owner_guid(int $guid)
Set the guid of the entity that owns this page.
Definition: pageowner.php:34
get_input(string $variable, $default=null, bool $filter_result=true)
Parameter input functions.
Definition: input.php:20
elgg_extract($key, $array, $default=null, bool $strict=true)
Checks for $array[$key] and returns its value if it exists, else returns $default.
Definition: elgglib.php:254
Handle muting notifications about an entity.
Definition: mute.php:6
elgg_entity_exists(int $guid)
Does an entity exist?
Definition: entities.php:88
elgg_call() flags
Definition: constants.php:130
get_entity(int $guid)
Loads and returns an entity object from a guid.
Definition: entities.php:67
elgg_view_page(string $title, string|array $body, string $page_shell= 'default', array $vars=[])
Assembles and outputs a full page.
Definition: views.php:256
get_user(int $guid)
Elgg users Functions to manage multiple or single users in an Elgg install.
Definition: users.php:16
Definition: theme.php:5
Definition: mute.php:7
Aggregate action for saving settings.
Definition: mute.php:8
var elgg
Definition: elgglib.js:4