Elgg  Version master
body.php
Go to the documentation of this file.
1 <?php
11 $subject = elgg_extract('subject', $vars);
13 
15 
17 
20 if ($email instanceof \Elgg\Email) {
21  $email_params = $email->getParams();
22 }
23 
26 $add_mute_link = (bool) elgg_extract('add_mute_link', $email_params, true);
27 
28 if ($add_mute_link && $object instanceof \ElggEntity && $recipient instanceof \ElggUser) {
29  $site_link .= ' | ' . elgg_view_url(elgg_http_get_signed_url(elgg_generate_url('notifications:mute', [
30  'entity_guid' => $object->guid,
31  'recipient_guid' => $recipient->guid,
32  ])), elgg_echo('notifications:mute:email:footer'));
33 }
34 
35 ?>
36 <table class="body-wrapper">
37  <tr>
38  <td>
39  <table class="edge-wrapper">
40  <tr>
41  <td>
42  <table class="content-wrapper">
43  <tr>
44  <td>
45  <table class="header">
46  <tr>
47  <td>
48  <h1><?= $body_title; ?></h1>
49  </td>
50  </tr>
51  </table>
52  <table class="content">
53  <tr>
54  <td>
55  <?= $body; ?>
56  </td>
57  </tr>
58  </table>
59  <table class="footer">
60  <tr>
61  <td>
62  <?= $site_link; ?>
63  </td>
64  </tr>
65  </table>
66  </td>
67  </tr>
68  </table>
69  </td>
70  </tr>
71  </table>
72  </td>
73  </tr>
74 </table>
$add_mute_link
Definition: body.php:26
$email_params
Definition: body.php:18
$recipient
Definition: body.php:25
elgg_echo(string $message_key, array $args=[], string $language= '')
Elgg language module Functions to manage language and translations.
Definition: languages.php:17
elgg_view_title(string $title, array $vars=[])
Renders a title.
Definition: views.php:815
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
$site_link
Definition: body.php:16
$email
Definition: body.php:19
elgg_get_site_entity()
Get the current site entity.
Definition: entities.php:99
if($email instanceof\Elgg\Email) $object
Definition: body.php:24
$body
Wrap form body.
Definition: body.php:11
$vars
Definition: theme.php:5
elgg_view_url(string $href, string $text=null, array $options=[])
Helper function for outputting urls.
Definition: views.php:1427
$body_title
Definition: body.php:14
elgg_generate_url(string $name, array $parameters=[])
Generate a URL for named route.
$subject
HTML body of an email.
Definition: body.php:11
elgg_http_get_signed_url(string $url, string $expires=null)
Signs provided URL with a SHA256 HMAC key.
Definition: elgglib.php:214
elgg_view_entity_url(\ElggEntity $entity, array $options=[])
Helper function for outputting a link to an entity.
Definition: views.php:1444