function process($tpl) { $tpl->assign("user", $this->_user); $tpl->assign("lastArticles", $this->_lastArticles); $tpl->assign("WEBAPP_WEBSITE_URL", WEBAPP_WEBSITE_URL); parent::process($tpl); }
public static function handleException($e) { $fc = new FrontController(); $page = new Page('error/500', $fc); $page->process(); $fc->getResponse()->send(); }
public function process(Request $req) { if (isset($req->data['blogId'])) { $this->model->setBlogId($req->data['blogId']); } $this->defaultSkin = $this->model->optionWithName('stylesheet'); return parent::process($req); }
public function run() { $path = $this->getRequest()->getRequestUri(); $path = trim($path, "\\/ \t\n\r\v"); ob_start(); try { $page = $this->_loadPage($path, self::$routes); if ($page instanceof Page) { $page->process(); } } catch (Exception $e) { $page = new Page('error', $this, array('errorCode' => 500)); $page->process(); } $contents = ob_get_contents(); ob_end_clean(); $this->getResponse()->setBody($contents); $this->getResponse()->send(); }
<? ob_start(); require_once( "resources/bin/constants.php"); add_required_class( 'Page.Class.php', MODEL ); //$application = new ApplicationSettings( "MedTeleNursing.AppSettings", ENVIRONMENT); $pageName = $_REQUEST[ 'page' ]; if($application->isPageGated($pageName)){ if(!$application->session->isSessionAuthenticated()){ $application->enforceGate(); } } $page = new Page( $pageName ); $page->process(); echo htmlspecialchars_decode( $page->output() ); echo ob_get_clean(); ?>