From c13a18b00b6c252d17113620e55810fb8dd26052 Mon Sep 17 00:00:00 2001 From: engineerTrooper Date: Sun, 20 Sep 2020 12:56:04 +0200 Subject: [PATCH] Test-Branch erstellt, Dev-Area for EngineerTrooper, base Editing, theme create --- conf/modules.inc.php | 9 +++++++ public/theme/engineers-dummy/css/base.css | 4 +++ public/theme/engineers-dummy/js/base.js | 0 src/modules/Engineers/TestController.php | 29 ++++++++++++++++++++++ tpl/engineers-dummy/base.php | 30 +++++++++++++++++++++++ tpl/engineers-dummy/header/head.php | 17 +++++++++++++ 6 files changed, 89 insertions(+) create mode 100644 conf/modules.inc.php create mode 100644 public/theme/engineers-dummy/css/base.css create mode 100644 public/theme/engineers-dummy/js/base.js create mode 100644 src/modules/Engineers/TestController.php create mode 100644 tpl/engineers-dummy/base.php create mode 100644 tpl/engineers-dummy/header/head.php diff --git a/conf/modules.inc.php b/conf/modules.inc.php new file mode 100644 index 0000000..16e30c0 --- /dev/null +++ b/conf/modules.inc.php @@ -0,0 +1,9 @@ + need to have the Module Class at parent with the init function ;) +$modules = []; + +// register controllers that can handle templates ;) need to have a render function for this +$controllers = [ + 'test' => \Modules\Engineers\TestController::class, +]; \ No newline at end of file diff --git a/public/theme/engineers-dummy/css/base.css b/public/theme/engineers-dummy/css/base.css new file mode 100644 index 0000000..3a5385e --- /dev/null +++ b/public/theme/engineers-dummy/css/base.css @@ -0,0 +1,4 @@ +body { + background-color: #333333; + color: #fff; +} \ No newline at end of file diff --git a/public/theme/engineers-dummy/js/base.js b/public/theme/engineers-dummy/js/base.js new file mode 100644 index 0000000..e69de29 diff --git a/src/modules/Engineers/TestController.php b/src/modules/Engineers/TestController.php new file mode 100644 index 0000000..999e031 --- /dev/null +++ b/src/modules/Engineers/TestController.php @@ -0,0 +1,29 @@ +addCSS('base', 'base.css'); + return true; + } + + public function getTemplate(): string + { + return 'base'; + } +} \ No newline at end of file diff --git a/tpl/engineers-dummy/base.php b/tpl/engineers-dummy/base.php new file mode 100644 index 0000000..4208bda --- /dev/null +++ b/tpl/engineers-dummy/base.php @@ -0,0 +1,30 @@ +getLang(); +?> + + +includeTemplate("header/head"); +?> + +
+ getTranslation("HEADLINE") ?> +
+
+

Mami ich mag dich

+ getTranslation("TEST_TRANSLATION"); + echo $this->templateData; + ?> +
+ +renderJS(); +?> + + \ No newline at end of file diff --git a/tpl/engineers-dummy/header/head.php b/tpl/engineers-dummy/header/head.php new file mode 100644 index 0000000..b299005 --- /dev/null +++ b/tpl/engineers-dummy/header/head.php @@ -0,0 +1,17 @@ + + + + + + + Engineers Dummy + renderCSS(); + ?> + +