Browse code

Test script injection

Benjamin Roth authored on11/12/2019 13:43:09
Showing3 changed files
... ...
@@ -12,7 +12,7 @@
12 12
 * Register PSR-0 namespace.
13 13
 */
14 14
 if (class_exists('NamespaceClassLoader')) {
15
-  NamespaceClassLoader::add('EsalesMedia\Cookieconsent', 'system/modules/cookieconsent/src');
15
+  NamespaceClassLoader::add('EsalesMedia\Cookieconsent', 'system/modules/eSM_cookieconsent/src');
16 16
 }
17 17
 /*
18 18
 * Register the templates
... ...
@@ -14,6 +14,9 @@ class TemplateListener
14 14
 {
15 15
   public function onOutputFrontendTemplate($strBuffer)
16 16
   {
17
+    $Template = new \FrontendTemplate('cookieconsent');
18
+
19
+    $Template->parse();
17 20
     return $strBuffer;
18 21
   }
19 22
 }
20 23
\ No newline at end of file
21 24
new file mode 100644
... ...
@@ -0,0 +1,2 @@
1
+<?php
2
+$GLOBALS['TL_JAVASCRIPT'][] = 'system/modules/eSM_cookieconsent/assets/js/lib/cookieconsent.min.js|static';
0 3
\ No newline at end of file