1 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,22 @@ |
1 |
+<?php |
|
2 |
+ |
|
3 |
+/* |
|
4 |
+* This file is part of eSales Media cookieconsent module |
|
5 |
+* |
|
6 |
+* (c) Benjamin Roth |
|
7 |
+* |
|
8 |
+* @license https://www.gnu.org/licenses/gpl-3.0.html GPL |
|
9 |
+*/ |
|
10 |
+ |
|
11 |
+namespace EsalesMedia\Cookieconsent\EventListener; |
|
12 |
+ |
|
13 |
+class TemplateListener |
|
14 |
+{ |
|
15 |
+ public function onOutputFrontendTemplate($strBuffer) |
|
16 |
+ { |
|
17 |
+ $Template = new \FrontendTemplate('cookieconsent'); |
|
18 |
+ |
|
19 |
+ $strInject = $Template->parse(); |
|
20 |
+ return str_replace('</body>',$strInject . '</body>',$strBuffer); |
|
21 |
+ } |
|
22 |
+} |
|
0 | 23 |
\ No newline at end of file |
1 | 24 |
deleted file mode 100644 |
... | ... |
@@ -1,22 +0,0 @@ |
1 |
-<?php |
|
2 |
- |
|
3 |
-/* |
|
4 |
-* This file is part of eSales Media cookieconsent module |
|
5 |
-* |
|
6 |
-* (c) Benjamin Roth |
|
7 |
-* |
|
8 |
-* @license https://www.gnu.org/licenses/gpl-3.0.html GPL |
|
9 |
-*/ |
|
10 |
- |
|
11 |
-namespace EsalesMedia\Cookieconsent\EventListener; |
|
12 |
- |
|
13 |
-class TemplateListener |
|
14 |
-{ |
|
15 |
- public function onOutputFrontendTemplate($strBuffer) |
|
16 |
- { |
|
17 |
- $Template = new \FrontendTemplate('cookieconsent'); |
|
18 |
- |
|
19 |
- $strInject = $Template->parse(); |
|
20 |
- return str_replace('</body>',$strInject . '</body>',$strBuffer); |
|
21 |
- } |
|
22 |
-} |
|
23 | 0 |
\ No newline at end of file |