File modules/template_engine/components/html/NativeHtmlComponent.class.php

Last commit: Sat Feb 22 22:23:01 2020 +0100	Jan Dankert	Refactoring: Enable Autoloading, Fix namespace structure.
1 <?php 2 3 namespace template_engine\components\html; 4 5 use template_engine\components\html\HtmlComponent; 6 use template_engine\element\HtmlElement; 7 8 class NativeHtmlComponent extends HtmlComponent 9 { 10 public $attributes; 11 public $tag; 12 13 public function createElement() 14 { 15 $html = new HtmlElement( $this->tag ); 16 17 foreach ($this->attributes as $attribute) 18 $html->addAttribute( $attribute->name,$attribute->value ); 19 20 return $html; 21 } 22 }
Download modules/template_engine/components/html/NativeHtmlComponent.class.php
History Sat, 22 Feb 2020 22:23:01 +0100 Jan Dankert Refactoring: Enable Autoloading, Fix namespace structure. Sat, 22 Feb 2020 01:58:20 +0100 Jan Dankert New: Autoloading of classes in all modules. Sat, 22 Feb 2020 00:46:59 +0100 Jan Dankert Refactoring: Renaming template-engine to template_engine because '-' is no valid namespace char.