<?php error_reporting(E_ALL); ini_set('display_errors', 1); require_once "controller/MasterController.php"; require_once "view/HTMLView.php"; $mc = new \controller\MasterController(); $mc->handleInput(); $view = $mc->generateOutput(); $htmlView = new \view\HTMLView("utf-8"); echo $htmlView->getHTMLPage("I like it!", $view->getHTML());
<?php // TODO: require right stuff in here! //INCLUDE THE FILES NEEDED... require_once 'Settings.php'; // view require_once 'view/LayoutView.php'; // controller require_once 'controller/MasterController.php'; if (\Settings::DisplayError) { error_reporting(E_ALL); ini_set('display_errors', 'On'); } $htmlView = new \view\LayoutView(); $masterController = new \controller\MasterController(); $masterController->run(); $view = $masterController->generateOutput(); $nav = $masterController->generateNavigation(); $htmlView->renderHTMLPage($view, $nav);
<?php require_once 'config.php'; $controller = new \controller\MasterController(); $controller->handleInput(); $page = new \view\ContentView(); echo $page->Render($controller->generateOutput(), $controller->IsLoggedIn());
<?php /** * Solution for assignment 2 * @author Daniel Toll */ require_once "Settings.php"; require_once "controller/MasterController.php"; require_once "model/DAL/Connect.php"; if (Settings::DISPLAY_ERRORS) { error_reporting(-1); ini_set('display_errors', 'ON'); } //session must be started before LoginModel is created session_start(); //Dependency injection $mc = new \controller\MasterController(); //Controller must be run first since state is changed $mc->doMasterControl(); //Generate output $mc->generateOutput();