diff --git a/classes/output/core_renderer.php b/classes/output/core_renderer.php index 1b3b6b0..efb5dde 100644 --- a/classes/output/core_renderer.php +++ b/classes/output/core_renderer.php @@ -244,6 +244,20 @@ public function get_global_header_data() { return $context; } + public function get_footer_data(): \stdClass { + $context = new \stdClass(); + + $dotnet_base_url = get_config('theme_nhse', 'dotnet_base_url'); + if (!empty($dotnet_base_url) && substr($dotnet_base_url, -1) !== '/') { + $dotnet_base_url .= '/'; + } + + $context->dotnet_base_url = $dotnet_base_url; + + return $context; + + } + public function standard_head_html() { $output = parent::standard_head_html(); diff --git a/templates/columns1.mustache b/templates/columns1.mustache index 3c5a7e8..08cbd67 100644 --- a/templates/columns1.mustache +++ b/templates/columns1.mustache @@ -69,7 +69,9 @@ {{{ output.standard_after_main_region_html }}} - {{> theme_nhse/footer }} + {{# output.get_footer_data }} + {{> theme_nhse/footer }} + {{/ output.get_footer_data }} {{{ output.standard_end_of_body_html }}} diff --git a/templates/columns2.mustache b/templates/columns2.mustache index b15af27..21b6b20 100644 --- a/templates/columns2.mustache +++ b/templates/columns2.mustache @@ -100,7 +100,9 @@ {{{ output.standard_after_main_region_html }}} - {{> theme_nhse/footer }} + {{# output.get_footer_data }} + {{> theme_nhse/footer }} + {{/ output.get_footer_data }} diff --git a/templates/drawers.mustache b/templates/drawers.mustache index 804f3d9..9cba579 100644 --- a/templates/drawers.mustache +++ b/templates/drawers.mustache @@ -179,7 +179,9 @@ - {{> theme_nhse/footer }} + {{# output.get_footer_data }} + {{> theme_nhse/footer }} + {{/ output.get_footer_data }} {{{ output.standard_after_main_region_html }}} diff --git a/templates/login.mustache b/templates/login.mustache index 594a241..65169d1 100644 --- a/templates/login.mustache +++ b/templates/login.mustache @@ -47,7 +47,9 @@ - {{> theme_nhse/footer }} + {{# output.get_footer_data }} + {{> theme_nhse/footer }} + {{/ output.get_footer_data }} {{{ output.standard_after_main_region_html }}} diff --git a/templates/secure.mustache b/templates/secure.mustache index a165532..6354e77 100644 --- a/templates/secure.mustache +++ b/templates/secure.mustache @@ -83,7 +83,9 @@ -{{> theme_nhse/footer }} +{{# output.get_footer_data }} + {{> theme_nhse/footer }} +{{/ output.get_footer_data }} {{#js}}