public function execute()
 {
     $page = new page();
     $page->addPlugin(new jqueryhook());
     $page->addPlugin(new bootstraphook());
     $page->addPlugin(new famoserhook());
     $page->addPlugin(new faviconshook());
     $page->addContent(new background("/images/background.jpg", "100%"));
     $times = new openingtimeshook("#openingtimes");
     $page->addPlugin($times);
     $nodes = $times->getOpeningTimesTableNodes(array(array("Montag", "07:30-12:00", "13:00-17:00"), array("Dienstag", "07:30-12:00", "13:00-17:00"), array("Mittwoch", "07:30-12:00", "13:00-17:00"), array("Donnerstag", "07:30-12:00", "13:00-18:00"), array("Freitag", "07:30-12:00", "13:00-17:00"), array("Samstag", "07:30-12:00", "geschlossen"), array("Sonntag", "geschlossen", "geschlossen")));
     $section = new section("Angebot", COLOR_PRIMARY_FOREGROUND, COLOR_PRIMARY_BACKGROUND);
     $section->addContent($nodes, 6);
     $div = new div("google-maps");
     $div->addCssElements(new simpleproperty(new width("100%")));
     $div->addCssElements(new simpleproperty(new height("260px")));
     $hook = new googlemapshook("#google-maps", 47.5458451, 7.5525755, "Neuweilerstrasse 112<br/>4060 Basel");
     $page->addPlugin($hook);
     $section->addContent($div, 6);
     $page->addContent($section);
     $section = new section("Kontakt", COLOR_SECONDARY_FOREGROUND, COLOR_SECONDARY_BACKGROUND);
     $kontaktplugin = new contactformhook();
     $section->addChildren($kontaktplugin->getBodyNodes());
     $page->addContent($section);
     $page->addContent(new footer());
     //read!: http://www.leyva.ch/SEO-Tutorial.pdf
     $page->render();
 }
 public function __construct($backgroundimagePath, $height, $absolute = false, $fixed = false, $id = null)
 {
     parent::__construct($id, null, null, "section", new simpleproperty(new padding(0)));
     $background = new \famoser\opc\css\properties\background(new \famoser\opc\css\properties\base\background('url("..' . $backgroundimagePath . '")'), new backgroundsize("cover"), $fixed);
     $this->addCssElements(new simpleproperty($background));
     $this->addCssElements(new simpleproperty(new width("100%")));
     $this->addCssElements(new simpleproperty(new height($height)));
     if ($absolute == true) {
         $this->addCssElements(new simpleproperty(new position("absolute")));
     }
 }
Exemple #3
0
 public function __construct($foreground = COLOR_GREY_DARK, $background = COLOR_GREY_LIGHT)
 {
     parent::__construct("debug", $foreground, $background);
     $div = new div();
     $div->addClass("wrapper");
     $p = new p();
     $p->addClass("text-center");
     $text = new text();
     $text->setText("try again @ ");
     $a = new a(ONEPAGECREATOR_HOOK);
     $p->addChildren($text);
     $p->addChildren($a);
     $div->addChildren($p);
     $this->addChildren($div);
 }
Exemple #4
0
 public function __construct($foreground = COLOR_GREY_DARK, $background = COLOR_GREY_LIGHT)
 {
     parent::__construct("footer", $foreground, $background, "footer", new responsiveproperty(new emptyproperty(), new padding(EXTRA_SMALL_SPACER, NO_SPACER, SMALL_SPACER, NO_SPACER), new padding(SMALL_SPACER, NO_SPACER, LARGE_SPACER, NO_SPACER), new padding(LARGE_SPACER, NO_SPACER, EXTRA_LARGE_SPACER, NO_SPACER), new padding(LARGE_SPACER, NO_SPACER, EXTRA_LARGE_SPACER, NO_SPACER)));
     $div = new div();
     $div->addClass("wrapper");
     $p = new p();
     $p->addClass("text-center");
     $text = new text();
     $text->setText("Copyright © " . AUTHOR_NAME . " - ");
     $a = new a(AUTHOR_PAGE, AUTHOR_PAGE, AUTHOR_NAME, "_self");
     $p->addChildren($text);
     $p->addChildren($a);
     $div->addChildren($p);
     $this->addChildren($div);
 }
Exemple #5
0
 public function __construct($foreground, $background)
 {
     parent::__construct("header", $foreground, $background, "header", new responsiveproperty(new emptyproperty(), new padding(EXTRA_SMALL_SPACER, NO_SPACER), new padding(SMALL_SPACER, NO_SPACER), new padding(EXTRA_SMALL_SPACER, NO_SPACER), new padding(SMALL_SPACER, NO_SPACER)));
     $this->setNode("header");
 }