Skip to content

Instantly share code, notes, and snippets.

@Gerjo
Created September 24, 2014 12:39
Show Gist options
  • Save Gerjo/6db0803e730eeaf505c7 to your computer and use it in GitHub Desktop.
Save Gerjo/6db0803e730eeaf505c7 to your computer and use it in GitHub Desktop.
Portfolio structure
class Portfolio extends Composite {
public function __construct() {
parent::__construct();
$this->addChild(
new Storage(),
new Template("../views/head.html"),
new Menu(
new Template("../views/menu.html")
),
new Home(new Template("../views/home.html")),
new Articles(new Template("../views/articles.html")),
new Games(new Template("../views/lab.html")),
new Lab(new Template("../views/lab.html")),
new Random(new Template("../views/random.html")),
new Edit(new Template("../views/edit.html")),
new Pasteplot(new Template("../views/pasteplot.html")),
new Vintage(new Template("../views/vintage.html")),
new Play(),
new Fences(new Template("../views/fences.html")),
//new Map(new Template("../views/map.html")),
new Template("../views/footer.html")
);
echo $this->compileDocument(array(new DemoFilter()));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment