Elgg  Version 4.3
foot.php
Go to the documentation of this file.
1 <?php
2 
3 echo elgg_format_element('script', [], elgg_view('initialize_elgg.js'));
4 
6 foreach ($js as $resource) {
7  $options = [
8  'src' => $resource->url,
9  ];
10 
11  if (!empty($resource->integrity)) {
12  $options['integrity'] = $resource->integrity;
13  $options['crossorigin'] = 'anonymous';
14  }
15 
17 }
18 
19 $deps = _elgg_services()->amdConfig->getDependencies();
20 ?>
21 <script>
22 require(<?= json_encode($deps, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT); ?>);
23 </script>
$resource
$js
Definition: foot.php:5
$options
Elgg admin footer.
Definition: footer.php:6
foreach($js as $resource) $deps
Definition: foot.php:19
elgg_format_element($tag_name, array $attributes=[], $text= '', array $options=[])
Format an HTML element.
Definition: output.php:135
elgg require
Throw an error if the required package isn&#39;t present.
Definition: deprecated.js:176
_elgg_services()
Get the global service provider.
Definition: elgglib.php:638
elgg_get_loaded_external_resources(string $type, string $location)
Get external resource descriptors.
elgg echo
Translates a string.
Definition: deprecated.js:530
elgg_view($view, $vars=[], $viewtype= '')
Return a parsed view.
Definition: views.php:179